完善发布配置:添加图标和优化构建

- 添加应用图标文件 (icon.ico, icon.icns, icon.png)
- 配置最大压缩以减小文件体积
- 修改Windows目标为portable版本,生成单文件exe
- 排除不必要的node_modules文件
- 完善作者信息
This commit is contained in:
farion1231
2025-08-06 22:42:55 +08:00
parent 75a5e8088e
commit 1a7c3fcec5
4 changed files with 11 additions and 2 deletions

BIN
build/icon.icns Normal file

Binary file not shown.

BIN
build/icon.ico Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 161 KiB

BIN
build/icon.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 64 KiB

View File

@@ -16,7 +16,7 @@
"dist": "electron-builder"
},
"keywords": [],
"author": "",
"author": "Jason Young",
"license": "MIT",
"devDependencies": {
"@types/node": "^20.0.0",
@@ -37,14 +37,23 @@
"build": {
"appId": "com.ccswitch.app",
"productName": "CC Switch",
"compression": "maximum",
"directories": {
"output": "release"
},
"files": [
"dist/**/*",
"node_modules/**/*",
"!node_modules/*/{CHANGELOG.md,README.md,readme.md}",
"!node_modules/*/{test,__tests__,tests,powered-test,example,examples}",
"!node_modules/*.d.ts",
"!node_modules/.bin"
],
"mac": {
"category": "public.app-category.developer-tools"
},
"win": {
"target": "nsis"
"target": "portable"
},
"linux": {
"target": "AppImage"