This commit is contained in:
Fioren 2024-03-16 16:33:12 +07:00 committed by GitHub
parent 97e0d46756
commit e503ee663a
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -2,7 +2,7 @@
# Check github connection stable or not:
check_connection() {
wget -q $(curl -s "https://api.github.com/repos/revanced/revanced-patches/releases/latest" | jq -r '.assets[] | select(.name == "patches.json") | .browser_download_url')
wget -q $(curl -s "https://api.github.com/repos/revanced/revanced-patches/releases/latest" | jq -r '.assets[] | select(.name == "patches.json") | .browser_download_url') || rm -f "patches.json"
if [ -f patches.json ]; then
echo "internet_error=0" >> $GITHUB_OUTPUT
echo -e "\e[32mGithub connection OK\e[0m"
@ -11,4 +11,4 @@ check_connection() {
echo -e "\e[31mGithub connection not stable!\e[0m"
fi
}
check_connection
check_connection