Created
June 4, 2014 20:54
-
-
Save ellisio/e0bddaf18be64391367b to your computer and use it in GitHub Desktop.
Scan for iTunes album art sizes.
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
#!/bin/bash | |
rm -rf images | |
mkdir images | |
for i in {1..1024} | |
do | |
for x in {1..100} | |
do | |
echo "Checking ${i}x${i}-${x}" | |
CODE=`curl -o /dev/null --silent --head --write-out '%{http_code}' http://a4.mzstatic.com/us/r30/Music/v4/d7/b9/de/d7b9de4b-89c0-bd93-fa99-f5508a453af2/KatyPerryiTunes.${i}x${i}-${x}.jpg` | |
if [ $CODE == "200" ]; then | |
wget -O images/${i}x${i}-${x}.jpg http://a4.mzstatic.com/us/r30/Music/v4/d7/b9/de/d7b9de4b-89c0-bd93-fa99-f5508a453af2/KatyPerryiTunes.${i}x${i}-${x}.jpg | |
fi | |
done | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment