|
@@ -44,7 +44,22 @@ module.exports = {
|
|
|
'!vite.config.web.{js,ts,mjs,cjs}',
|
|
'!vite.config.web.{js,ts,mjs,cjs}',
|
|
|
'!{.eslintcache,eslint.config.mjs,.prettierignore,.prettierrc.yaml,dev-app-update.yml,CHANGELOG.md,README.md}',
|
|
'!{.eslintcache,eslint.config.mjs,.prettierignore,.prettierrc.yaml,dev-app-update.yml,CHANGELOG.md,README.md}',
|
|
|
'!{.env,.env.*,.npmrc,pnpm-lock.yaml}',
|
|
'!{.env,.env.*,.npmrc,pnpm-lock.yaml}',
|
|
|
- '!{tsconfig.json,tsconfig.node.json,tsconfig.web.json}'
|
|
|
|
|
|
|
+ '!{tsconfig.json,tsconfig.node.json,tsconfig.web.json}',
|
|
|
|
|
+ // --- 体积优化:Vite 已按需打包所需代码,asar 中无需保留完整依赖包 ---
|
|
|
|
|
+ '!node_modules/@vicons/**',
|
|
|
|
|
+ '!node_modules/echarts/lib/chart/map/**',
|
|
|
|
|
+ '!node_modules/echarts/lib/component/dataZoom/**',
|
|
|
|
|
+ '!node_modules/echarts/lib/component/toolbox/**',
|
|
|
|
|
+ '!node_modules/echarts/lib/component/visualMap/**',
|
|
|
|
|
+ '!node_modules/echarts/lib/component/graphic/**',
|
|
|
|
|
+ '!node_modules/echarts/lib/component/title/**',
|
|
|
|
|
+ '!node_modules/echarts/lib/component/tooltip/**',
|
|
|
|
|
+ '!node_modules/echarts/lib/component/axis/**',
|
|
|
|
|
+ '!node_modules/echarts/lib/component/grid/**',
|
|
|
|
|
+ '!node_modules/echarts/lib/renderer/**',
|
|
|
|
|
+ // naive-ui 源码已被 Vite 打包进 renderer JS,asar 中无需保留完整 es/lib 目录
|
|
|
|
|
+ '!node_modules/naive-ui/es/**',
|
|
|
|
|
+ '!node_modules/naive-ui/lib/**',
|
|
|
],
|
|
],
|
|
|
asarUnpack: ['resources/**'],
|
|
asarUnpack: ['resources/**'],
|
|
|
|
|
|
|
@@ -63,7 +78,8 @@ module.exports = {
|
|
|
perMachine: true, // true 为安装到 Program Files,false 为 AppData
|
|
perMachine: true, // true 为安装到 Program Files,false 为 AppData
|
|
|
createDesktopShortcut: true,
|
|
createDesktopShortcut: true,
|
|
|
createStartMenuShortcut: true,
|
|
createStartMenuShortcut: true,
|
|
|
- uninstallDisplayName: 'Scas Tool'
|
|
|
|
|
|
|
+ uninstallDisplayName: 'Scas Tool',
|
|
|
|
|
+ deleteAppDataOnUninstall: false,
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
// --- macOS 配置 ---
|
|
// --- macOS 配置 ---
|