Forked from marcuswestin/generate-iOS-app-icons.sh
Last active
December 14, 2017 14:38
-
-
Save yene/1b5e980a1af28f4f5d37 to your computer and use it in GitHub Desktop.
generate iOS icons
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 | |
# pass in the file name of the source as first parameter | |
mkdir -p generated | |
rm generated/* | |
# remove alpha with a simple trick | |
sips -s format bmp "$1" --out tmp.bmp | |
sips -s format png tmp.bmp --out "$1" | |
rm tmp.bmp | |
# cutting AppIcon for iOS | |
sips -Z 20 --out generated/[email protected] "$1" | |
sips -Z 40 --out generated/[email protected] "$1" | |
sips -Z 60 --out generated/[email protected] "$1" | |
sips -Z 29 --out generated/[email protected] "$1" | |
sips -Z 58 --out generated/[email protected] "$1" | |
sips -Z 87 --out generated/[email protected] "$1" | |
sips -Z 40 --out generated/[email protected] "$1" | |
sips -Z 80 --out generated/[email protected] "$1" | |
sips -Z 120 --out generated/[email protected] "$1" | |
sips -Z 57 --out generated/[email protected] "$1" | |
sips -Z 114 --out generated/[email protected] "$1" | |
sips -Z 120 --out generated/[email protected] "$1" # quality check this, iPhone < 6 icon | |
sips -Z 180 --out generated/[email protected] "$1" # quality check this, iPhone > 6 icon | |
sips -Z 50 --out generated/[email protected] "$1" | |
sips -Z 100 --out generated/[email protected] "$1" | |
sips -Z 72 --out generated/[email protected] "$1" | |
sips -Z 144 --out generated/[email protected] "$1" | |
sips -Z 76 --out generated/[email protected] "$1" | |
sips -Z 152 --out generated/[email protected] "$1" # quality check this, iPad icon | |
sips -Z 167 --out generated/[email protected] "$1" # quality check this, iPad Pro icon | |
sips -Z 1024 --out generated/[email protected] "$1" # quality check this, it is shown in the App Store | |
# cutting AppIcon for watchOS | |
#sips -Z 48 --out generated/[email protected] "$1" | |
#sips -Z 55 --out generated/[email protected] "$1" | |
#sips -Z 58 --out generated/[email protected] "$1" | |
#sips -Z 87 --out generated/[email protected] "$1" | |
#sips -Z 40 --out generated/[email protected] "$1" | |
#sips -Z 88 --out generated/[email protected] "$1" | |
#sips -Z 172 --out generated/[email protected] "$1" | |
#sips -Z 196 --out generated/[email protected] "$1" | |
#sips -Z 1024 --out generated/[email protected] "$1" | |
echo "cut all the images and placed them into the folder ./generated" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment