check for internet
This commit is contained in:
@ -5,7 +5,15 @@
|
||||
#gallery-dl --config ./config.json --input-file-delete to_download_r34.txt
|
||||
|
||||
if [ ! -s to_download_r34.txt ]; then
|
||||
#success! just exit
|
||||
echo "file empty"
|
||||
exit 0
|
||||
else
|
||||
echo "file not empty"
|
||||
if [ $(ping -qc 3 rule34.xxx) ]; then
|
||||
echo "has internet"
|
||||
else
|
||||
echo "no internet"
|
||||
exit 1
|
||||
fi
|
||||
fi
|
||||
|
Reference in New Issue
Block a user