Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/bin/sh
- [ $1 ] || echo "tell me the input icon image file"
- [ $1 ] || exit 1
- [ -f $1 ] || echo "input [$1] is not there"
- [ -f $1 ] || exit 1
- echo "resizing [$1] to generate ios and android icons"
- # android icons
- for i in \
- "-resize 36x36 android/icon_ldpi.png" \
- "-resize 48x48 android/icon_mdpi.png" \
- "-resize 72x72 android/icon_hdpi.png" \
- "-resize 96x96 android/icon_xhdpi.png"
- do
- echo "$1 $i"
- convert $1 $i
- done
- # ios icons
- for i in \
- "-resize 180x180 ios/[email protected]" \
- "-resize 60x60 ios/icon-60.png" \
- "-resize 120x120 ios/[email protected]" \
- "-resize 76x76 ios/icon-76.png" \
- "-resize 152x152 ios/[email protected]" \
- "-resize 40x40 ios/icon-40.png" \
- "-resize 80x80 ios/[email protected]" \
- "-resize 57x57 ios/icon.png" \
- "-resize 114x114 ios/[email protected]" \
- "-resize 72x72 ios/icon-72.png" \
- "-resize 144x144 ios/[email protected]" \
- "-resize 29x29 ios/icon-small.png" \
- "-resize 58x58 ios/[email protected]" \
- "-resize 50x50 ios/icon-50.png" \
- "-resize 100x100 ios/[email protected]"
- do
- echo "$1 $i"
- convert $1 $i
- done
Advertisement
Add Comment
Please, Sign In to add comment