This repository was archived by the owner on Jun 24, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 6 files changed +11
-6
lines changed Expand file tree Collapse file tree 6 files changed +11
-6
lines changed Original file line number Diff line number Diff line change @@ -5,24 +5,29 @@ if ! command -v magick &> /dev/null; then
5
5
exit 1
6
6
fi
7
7
8
+ if ! command -v inkscape & > /dev/null; then
9
+ echo " This tool requires Inkscape to be render sharper SVGs than ImageMagick."
10
+ exit 1
11
+ fi
12
+
8
13
if ! command -v icnsutil & > /dev/null; then
9
14
echo " This tool requires icnsutil to be installed in order to generate macOS icons."
10
15
exit 1
11
16
fi
12
17
13
18
script_dir=$( realpath $( dirname $0 ) )
14
19
cd " ${script_dir} /../images/app-icons"
15
- magick -background none " ../icon-color.svg" -resize 180x180 " ./ios/apple-touch-icon.png"
20
+ inkscape -w 180 -h 180 " ../icon-color.svg" -o " ./ios/apple-touch-icon.png"
16
21
17
22
# Build PNGs
18
- magick -background none " ../icon-color.svg" -resize " 128x128 " " ./png/128x128.png"
19
- magick -background none " ../icon-color.svg" -resize " 256x256 " " ./png/256x256.png"
20
- magick -background none " ../icon-purple.svg" -resize " 256x256 " " ./png/256x256-dev.png"
23
+ inkscape -w 128 -h 128 " ../icon-color.svg" -o " ./png/128x128.png"
24
+ inkscape -w 256 -h 256 " ../icon-color.svg" -o " ./png/256x256.png"
25
+ inkscape -w 256 -h 256 " ../icon-purple.svg" -o " ./png/256x256-dev.png"
21
26
22
27
# Build Mac .icns
23
- declare -a sizes=(" 16x16 " " 32x32 " " 512x512 " " 1024x1024 " )
28
+ declare -a sizes=(" 16 " " 32 " " 512 " " 1024 " )
24
29
for size in " ${sizes[@]} " ; do
25
- magick -background none " ../icon-color.svg" -resize " ${size} " " ./png/${size} .png"
30
+ inkscape -w $size -h $size " ../icon-color.svg" -o " ./png/${size} x ${size} .png"
26
31
done
27
32
icnsutil compose -f " mac/icon.icns" " ./png/16x16.png" " ./png/32x32.png" " ./png/128x128.png" " ./png/512x512.png" " ./png/1024x1024.png"
28
33
You can’t perform that action at this time.
0 commit comments