liamcottle___reticulum-mesh.../package.json
Danil Bezborodov 1518013225 Add support for universal Mac build (x64 + arm64)
Changes to package.json:
- Enable ASAR packaging (was disabled)
- Replace extraFiles with extraResources for Python executables
  - Old: Resources/app/electron/build/exe
  - New: Resources/python (outside ASAR, accessible to spawn)
- Mac: Add universal build support (x64 + arm64 in single .dmg)
- Mac: Add x64ArchFiles rule for Python (cx_Freeze creates universal binaries)
- Mac: Add explicit icon configuration
- Mac: Update artifact name to include architecture
- Remove buildResources directive (conflicted with extraResources)
- Remove duplicate extraFiles from win/linux sections (centralized)
- Add npm scripts: dist:mac-arm64 and dist:mac-universal

Changes to electron/main.js:
- Update Python exe path resolution for extraResources location
- Check process.resourcesPath/python first (production build)
- Fall back to local build/exe for development

Changes to .github/workflows/build.yml:
- Switch Mac runner from macos-13 (Intel) to macos-14 (Apple Silicon)
- Update artifacts pattern from '*-mac.dmg' to '*-mac-*.dmg'
2025-11-08 08:46:20 +03:00

108 lines
3 KiB
JSON

{
"name": "reticulum-meshchat",
"version": "2.2.1",
"description": "",
"main": "electron/main.js",
"scripts": {
"watch": "npm run build-frontend -- --watch",
"build-frontend": "vite build",
"build-backend": "python setup.py build",
"build": "npm run build-frontend && npm run build-backend",
"electron-postinstall": "electron-builder install-app-deps",
"electron": "npm run electron-postinstall && npm run build && electron .",
"dist": "npm run electron-postinstall && npm run build && electron-builder --publish=never",
"dist:mac-arm64": "npm run electron-postinstall && npm run build && electron-builder --mac --arm64 --publish=never",
"dist:mac-universal": "npm run electron-postinstall && npm run build && electron-builder --mac --universal --publish=never"
},
"license": "MIT",
"engines": {
"node": ">=18"
},
"devDependencies": {
"electron": "^30.0.8",
"electron-builder": "^24.6.3"
},
"build": {
"appId": "com.liamcottle.reticulummeshchat",
"productName": "Reticulum MeshChat",
"asar": true,
"extraResources": [
{
"from": "build/exe",
"to": "python",
"filter": ["**/*"]
}
],
"files": [
"electron/*.js",
"electron/*.html",
"electron/assets/**/*",
"public/**/*",
"package.json"
],
"mac": {
"target": {
"target": "dmg",
"arch": [
"universal"
]
},
"identity": null,
"icon": "electron/build/icon.png",
"artifactName": "ReticulumMeshChat-v${version}-${os}-${arch}.${ext}",
"x64ArchFiles": "Contents/Resources/python/**/*",
"extendInfo": {
"NSMicrophoneUsageDescription": "Microphone access is only needed for Audio Calls",
"com.apple.security.device.audio-input": true
}
},
"win": {
"artifactName": "ReticulumMeshChat-v${version}-${os}.${ext}",
"target": [
{
"target": "portable"
},
{
"target": "nsis"
}
]
},
"linux": {
"artifactName": "ReticulumMeshChat-v${version}-${os}.${ext}",
"target": "AppImage"
},
"dmg": {
"writeUpdateInfo": false
},
"portable": {
"artifactName": "ReticulumMeshChat-v${version}-${os}-portable.${ext}"
},
"nsis": {
"artifactName": "ReticulumMeshChat-v${version}-${os}-installer.${ext}",
"oneClick": false,
"allowToChangeInstallationDirectory": true
}
},
"dependencies": {
"@mdi/js": "^7.4.47",
"@tailwindcss/forms": "^0.5.9",
"@vitejs/plugin-vue": "^5.2.1",
"autoprefixer": "^10.4.20",
"axios": "^1.10.0",
"click-outside-vue3": "^4.0.1",
"compressorjs": "^1.2.1",
"electron-prompt": "^1.7.0",
"micron-parser": "^1.0.2",
"mitt": "^3.0.1",
"moment": "^2.30.1",
"postcss": "^8.4.49",
"protobufjs": "^7.4.0",
"tailwindcss": "^3.4.17",
"vis-data": "^7.1.9",
"vis-network": "^9.1.9",
"vite": "^6.0.5",
"vite-plugin-vuetify": "^2.0.4",
"vue-router": "^4.5.0",
"vuetify": "^3.7.6"
}
}