Created
July 3, 2015 06:53
-
-
Save TheHiddenHaku/653576d25dc9105c083a to your computer and use it in GitHub Desktop.
Check if url is 404
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
read -e -p "Inserisci la URL da controllare: " yourURL | |
while [ 1 ] | |
do | |
if curl --output /dev/null --silent --head --fail "$yourURL" | |
then | |
echo "This URL Exist" | |
open $yourURL | |
exit | |
else | |
echo "This URL Not Exist" | |
fi | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment