Skip to content

Instantly share code, notes, and snippets.

@fgarcia
Created September 26, 2012 10:23
Show Gist options
  • Save fgarcia/3787218 to your computer and use it in GitHub Desktop.
Save fgarcia/3787218 to your computer and use it in GitHub Desktop.
check if url is valid
#!/bin/sh
wget http://www.yahoo.com/ >/dev/null 2>&1
if [[ $? == 0 ]]; then
echo "found it."
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment