修改: - BUILD_WINDOWS.md: 更新构建说明 - 强调推荐在 Windows 上构建 - 添加手动打包步骤 - 整理常见问题解答 - package.json: 添加 forceCodeSigning 配置 原因: - Linux 下 electron-builder 需要 Wine 且网络要求高 - 手动打包提供更灵活的替代方案 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
77 lines
2.1 KiB
JSON
77 lines
2.1 KiB
JSON
{
|
|
"name": "impress-asr-input",
|
|
"version": "0.1.0",
|
|
"description": "基于 ONNX 的本地语音识别输入工具,支持多语言实时识别",
|
|
"main": "dist/main.js",
|
|
"type": "module",
|
|
"scripts": {
|
|
"dev": "tsx watch src/main.ts",
|
|
"build": "tsc",
|
|
"start": "node dist/main.js",
|
|
"dev:electron": "electron .",
|
|
"build:electron": "tsc && electron-builder",
|
|
"build:win": "cross-env ELECTRON_MIRROR=https://npmmirror.com/mirrors/electron/ npm run build:electron -- --win --x64",
|
|
"build:win:zip": "cross-env ELECTRON_MIRROR=https://npmmirror.com/mirrors/electron/ tsc && electron-builder --win zip --x64 --publish=never",
|
|
"build:win:dir": "cross-env ELECTRON_MIRROR=https://npmmirror.com/mirrors/electron/ tsc && electron-builder --win --x64 --dir --publish=never",
|
|
"test": "vitest run",
|
|
"lint": "eslint src --ext .ts"
|
|
},
|
|
"keywords": [
|
|
"asr",
|
|
"speech-to-text",
|
|
"onnx",
|
|
"voice-input",
|
|
"electron"
|
|
],
|
|
"author": "",
|
|
"license": "MIT",
|
|
"devDependencies": {
|
|
"@types/node": "^20.11.0",
|
|
"cross-env": "^7.0.3",
|
|
"electron": "^28.0.0",
|
|
"electron-builder": "^24.9.0",
|
|
"typescript": "^5.3.0",
|
|
"vitest": "^1.2.0"
|
|
},
|
|
"dependencies": {
|
|
"clipboardy": "^4.0.0",
|
|
"commander": "^12.0.0",
|
|
"onnxruntime-web": "^1.17.0"
|
|
},
|
|
"build": {
|
|
"appId": "com.impress.asr-input",
|
|
"productName": "Impress ASR Input",
|
|
"buildVersion": "1.0.0",
|
|
"publish": null,
|
|
"directories": {
|
|
"output": "release",
|
|
"buildResources": "build"
|
|
},
|
|
"files": [
|
|
"dist/**/*",
|
|
"src/ui/**/*",
|
|
"models/**/*"
|
|
],
|
|
"extraResources": [
|
|
"models/*.onnx"
|
|
],
|
|
"win": {
|
|
"target": "zip",
|
|
"requestedExecutionLevel": "asInvoker",
|
|
"forceCodeSigning": false,
|
|
"artifactName": "${productName}-${version}-win-${arch}.${ext}"
|
|
},
|
|
"mac": {
|
|
"target": ["dmg", "zip"],
|
|
"category": "public.app-category.utilities"
|
|
},
|
|
"linux": {
|
|
"target": ["AppImage", "deb"],
|
|
"category": "Utility"
|
|
}
|
|
},
|
|
"engines": {
|
|
"node": ">=20.0.0"
|
|
}
|
|
}
|