mirror of
https://github.com/LifeArchiveProject/WeChatDataAnalysis.git
synced 2026-02-19 22:30:49 +08:00
- 集成 electron-updater:检查更新/下载/安装/忽略此版本,并推送下载进度到前端 - 打包版启动后自动检查更新;托盘菜单支持手动检查 - preload 暴露 updater IPC + __brand 标记;前端新增更新弹窗与设置页版本/检查更新入口 - 补全发布配置:artifactName/publish;release workflow 增加上传 latest.yml
69 lines
2.0 KiB
JSON
69 lines
2.0 KiB
JSON
{
|
|
"name": "wechat-data-analysis-desktop",
|
|
"private": true,
|
|
"version": "1.3.0",
|
|
"main": "src/main.cjs",
|
|
"scripts": {
|
|
"dev": "concurrently -k -s first \"cd ..\\\\frontend && npm run dev\" \"cross-env ELECTRON_START_URL=http://localhost:3000 electron .\"",
|
|
"dev:static": "pushd ..\\\\frontend && npm run generate && popd && cross-env ELECTRON_START_URL=http://127.0.0.1:8000 electron .",
|
|
"build:ui": "pushd ..\\\\frontend && npm run generate && popd && node scripts\\\\copy-ui.cjs",
|
|
"build:backend": "uv sync --extra build && node scripts/build-backend.cjs",
|
|
"build:icon": "node scripts/build-icon.cjs",
|
|
"dist": "npm run build:ui && npm run build:backend && npm run build:icon && electron-builder --win --x64 --publish never"
|
|
},
|
|
"dependencies": {
|
|
"electron-updater": "^6.7.3"
|
|
},
|
|
"build": {
|
|
"appId": "com.lifearchive.wechatdataanalysis",
|
|
"productName": "WeChatDataAnalysis",
|
|
"artifactName": "${productName}-${version}-Setup.${ext}",
|
|
"icon": "build/icon.ico",
|
|
"asar": true,
|
|
"directories": {
|
|
"output": "dist"
|
|
},
|
|
"files": [
|
|
"src/**/*",
|
|
"package.json"
|
|
],
|
|
"extraResources": [
|
|
{
|
|
"from": "resources/ui",
|
|
"to": "ui"
|
|
},
|
|
{
|
|
"from": "resources/backend",
|
|
"to": "backend"
|
|
}
|
|
],
|
|
"win": {
|
|
"icon": "build/icon.ico",
|
|
"target": [
|
|
"nsis"
|
|
]
|
|
},
|
|
"publish": {
|
|
"provider": "github",
|
|
"owner": "LifeArchiveProject",
|
|
"repo": "WeChatDataAnalysis",
|
|
"releaseType": "release"
|
|
},
|
|
"nsis": {
|
|
"oneClick": false,
|
|
"allowToChangeInstallationDirectory": true,
|
|
"include": "scripts/installer-custom.nsh",
|
|
"installerIcon": "build/installerIcon.ico",
|
|
"uninstallerIcon": "build/uninstallerIcon.ico",
|
|
"installerHeaderIcon": "build/installerHeaderIcon.ico"
|
|
}
|
|
},
|
|
"devDependencies": {
|
|
"concurrently": "^9.2.1",
|
|
"cross-env": "^10.1.0",
|
|
"electron": "^40.0.0",
|
|
"electron-builder": "^26.4.0",
|
|
"png-to-ico": "^3.0.1"
|
|
}
|
|
}
|