It is not a programmer's job to tailor an icon of every size needed to the shelves one at a time before the app is put on the shelves, and using the SIPs tool from the MAC can solve this requirement.
With respect to SIPs, the following information can appear in the terminal directly:
Copy Code code as follows:
SIPs 10.4.4-scriptable image processing system.
This tool are used to query or modify raster image files and ColorSync ICC profiles.
Its functionality can also is used through the "Image Events" AppleScript suite.
Try ' sips--help ' or ' sips--helpproperties ' for help using this tool
It is a script image processing system that can be used to query and modify image files.
The following is just written iOS App icon crop script, saved into a. sh file, in the terminal input SH xx.sh can be executed:
Copy Code code as follows:
#!/bin/sh
Filename= "Icon.png"
Dirname= "Cutimg"
name_array= ("Icon-29.png" "Icon-29@2x.png" "Icon-40@2x.png" "Icon-57.png" "Icon-57@2x.png" "Icon-120.png")
size_array= ("29" "58" "80" "57" "114" "120")
mkdir $dirname
For ((i=0;i<${#name_array [@]};++i)); Todo
M_dir= $dirname/${name_array[i]}
CP $filename $m _dir
Sips-z ${size_array[i]} $m _dir
Done