Skip to content

Instantly share code, notes, and snippets.

@programmarchy
Last active May 12, 2020 10:11
Show Gist options
  • Save programmarchy/e2d4e6c2e42fab2525ff70bc31145a32 to your computer and use it in GitHub Desktop.
Save programmarchy/e2d4e6c2e42fab2525ff70bc31145a32 to your computer and use it in GitHub Desktop.
Given a high resolution icon image, use imagemagick to scale down to all iOS app icon dimensions
APP_NAME="YOUR_APP_NAME_HERE"
SRC=./Design/AppIcon.png
DST=./$APP_NAME/Assets.xcassets/AppIcon.appiconset
convert $SRC -resize 1024x1024 "$DST/AppIcon1024x1024.png"
convert $SRC -resize 2048x2048 "$DST/AppIcon2048x2048.png"
convert $SRC -resize 29x29 "$DST/AppIcon29x29.png"
convert $SRC -resize 58x58 "$DST/[email protected]"
convert $SRC -resize 87x87 "$DST/[email protected]"
convert $SRC -resize 80x80 "$DST/[email protected]"
convert $SRC -resize 120x120 "$DST/[email protected]"
convert $SRC -resize 57x57 "$DST/AppIcon57x57.png"
convert $SRC -resize 114x114 "$DST/[email protected]"
convert $SRC -resize 120x120 "$DST/[email protected]"
convert $SRC -resize 180x180 "$DST/[email protected]"
convert $SRC -resize 29x29 "$DST/AppIcon29x29~iPad.png"
convert $SRC -resize 58x58 "$DST/[email protected]"
convert $SRC -resize 40x40 "$DST/AppIcon40x40~iPad.png"
convert $SRC -resize 80x80 "$DST/[email protected]"
convert $SRC -resize 50x50 "$DST/AppIcon50x50~iPad.png"
convert $SRC -resize 100x100 "$DST/[email protected]"
convert $SRC -resize 72x72 "$DST/AppIcon72x72~iPad.png"
convert $SRC -resize 144x144 "$DST/[email protected]"
convert $SRC -resize 76x76 "$DST/AppIcon76x76~iPad.png"
convert $SRC -resize 76x76 "$DST/AppIcon76x76~iPad.png"
convert $SRC -resize 152x152 "$DST/[email protected]"
convert $SRC -resize 167x167 "$DST/[email protected]"
convert $SRC -resize 40x40 "$DST/[email protected]"
convert $SRC -resize 60x60 "$DST/[email protected]"
convert $SRC -resize 20x20 "$DST/NotificationIcon20x20~iPad.png"
convert $SRC -resize 40x40 "$DST/[email protected]"
convert $SRC -resize 48x48 "$DST/[email protected]"
convert $SRC -resize 55x55 "$DST/[email protected]"
convert $SRC -resize 58x58 "$DST/[email protected]"
convert $SRC -resize 87x87 "$DST/[email protected]"
convert $SRC -resize 40x40 "$DST/WatchIcon40x40.png"
convert $SRC -resize 80x80 "$DST/[email protected]"
convert $SRC -resize 88x88 "$DST/[email protected]"
convert $SRC -resize 172x172 "$DST/[email protected]"
convert $SRC -resize 196x196 "$DST/[email protected]"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment