Last active
January 9, 2020 11:28
-
-
Save Porrapat/f00513ce566261b20679333b6eda7f8b to your computer and use it in GitHub Desktop.
This file contains 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
# Curl to list of website and get it's title html tag | |
# Useful for checking code quality of many websites. | |
# requirement : you must install HTML-XML-utils first by | |
# sudo apt-get install html-xml-utils | |
now=$(date) | |
URLs=( | |
"google.com" | |
"facebook.com" | |
"ideavivat.com" | |
) | |
for URL in "${URLs[@]}" | |
do | |
echo "For $URL" | |
curl -sL "$URL" | hxnormalize -x 2>/dev/null | hxselect -c 'title' | tr -d '\n' ; echo "" | |
echo "================" | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment