配置应用图标:支持 Windows NSIS 安装包正确显示图标
- 添加跨平台图标配置(Windows .ico、macOS .icns、Linux .png) - 配置 Windows 双重构建目标:NSIS 安装程序 + Portable 版本 - 解决 Windows 下 exe 文件显示默认图标的问题 - NSIS 安装程序版本可正确显示自定义图标
This commit is contained in:
19
package.json
19
package.json
@@ -41,6 +41,7 @@
|
||||
"directories": {
|
||||
"output": "release"
|
||||
},
|
||||
"icon": "build/icon.ico",
|
||||
"files": [
|
||||
"dist/**/*",
|
||||
"node_modules/**/*",
|
||||
@@ -50,13 +51,25 @@
|
||||
"!node_modules/.bin"
|
||||
],
|
||||
"mac": {
|
||||
"category": "public.app-category.developer-tools"
|
||||
"category": "public.app-category.developer-tools",
|
||||
"icon": "build/icon.icns"
|
||||
},
|
||||
"win": {
|
||||
"target": "portable"
|
||||
"target": [
|
||||
{
|
||||
"target": "nsis",
|
||||
"arch": ["x64"]
|
||||
},
|
||||
{
|
||||
"target": "portable",
|
||||
"arch": ["x64"]
|
||||
}
|
||||
],
|
||||
"icon": "build/icon.ico"
|
||||
},
|
||||
"linux": {
|
||||
"target": "AppImage"
|
||||
"target": "AppImage",
|
||||
"icon": "build/icon.png"
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user