File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -28,17 +28,17 @@ function generateAdaptiveIcons(input, output) {
2828 const backgroundFile = path . join ( dir , 'ic_launcher_background.png' )
2929 const foregroundFile = path . join ( dir , 'ic_launcher_foreground.png' )
3030
31- // 背景:纯色填充(全覆盖)
31+ // linux只能convert, 背景:纯色填充(全覆盖)
3232 execSync (
33- `magick -size ${ size } x${ size } canvas:"${ bgColor } " ${ backgroundFile } `
33+ `convert -size ${ size } x${ size } canvas:"${ bgColor } " ${ backgroundFile } `
3434 )
3535
3636 // 前景大小 = 图标尺寸 × 0.75
3737 const fgSize = Math . round ( size * foregroundScale )
3838
3939 // 前景:缩放到安全区域,居中,四周自动留边
4040 execSync (
41- `magick "${ input } " -resize ${ fgSize } x${ fgSize } ` +
41+ `convert "${ input } " -resize ${ fgSize } x${ fgSize } ` +
4242 `-gravity center -background none -extent ${ size } x${ size } ${ foregroundFile } `
4343 )
4444 }
You can’t perform that action at this time.
0 commit comments