Skip to content

Instantly share code, notes, and snippets.

@tonsV2
Created October 10, 2013 18:10
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tonsV2/6922887 to your computer and use it in GitHub Desktop.
Save tonsV2/6922887 to your computer and use it in GitHub Desktop.
#! /bin/sh
if [ $# -eq 0 ] ; then
echo "Usage: $0 ICON_FILE PROJECT_DIR"
exit 0
fi
ICON="$1"
PROJECT="$2"
convert $ICON -resize 512x512 "ic_launcher_512x512.png"
convert $ICON -resize 144x144 "$PROJECT/src/main/res/drawable-xxhdpi/ic_launcher.png"
convert $ICON -resize 96x96 "$PROJECT/src/main/res/drawable-xhdpi/ic_launcher.png"
convert $ICON -resize 72x72 "$PROJECT/src/main/res/drawable-hdpi/ic_launcher.png"
convert $ICON -resize 48x48 "$PROJECT/src/main/res/drawable-mdpi/ic_launcher.png"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment