From a74a6869ea052fa169fdb8603f456e7fd0cdab98 Mon Sep 17 00:00:00 2001 From: Ivan Date: Mon, 1 Dec 2025 12:37:44 -0600 Subject: [PATCH 1/6] chore: enhance build configuration for macOS and update artifact naming - Added new distribution scripts for macOS ARM64 and universal builds in package.json. - Updated macOS target configuration to support universal architecture. - Modified GitHub Actions workflow to use macOS 14 and adjusted artifact naming for macOS DMG files. --- .github/workflows/build.yml | 6 +++--- package.json | 13 ++++++++++--- 2 files changed, 13 insertions(+), 6 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index c00c353..22c8e2b 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -80,10 +80,10 @@ jobs: release_artifacts: "dist/*-win-installer.exe,dist/*-win-portable.exe" build_input: build_windows - name: mac - os: macos-13 + os: macos-14 node: 18 python: "3.11" - release_artifacts: "dist/*-mac.dmg" + release_artifacts: "dist/*-mac-*.dmg" build_input: build_mac - name: linux os: ubuntu-latest @@ -173,7 +173,7 @@ jobs: mv dist/*.whl python-dist/ rm -rf dist - - name: Build Electron App + - name: Build Electron App (Universal) if: | github.event_name == 'push' || (github.event_name == 'workflow_dispatch' && inputs[matrix.build_input] == true) diff --git a/package.json b/package.json index 9f6b59b..0da9252 100644 --- a/package.json +++ b/package.json @@ -12,7 +12,9 @@ "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-prebuilt": "npm run electron-postinstall && npm run build-backend && electron-builder --publish=never" + "dist-prebuilt": "npm run electron-postinstall && npm run build-backend && 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": { @@ -36,9 +38,14 @@ "buildResources": "electron/build" }, "mac": { - "target": "dmg", + "target": { + "target": "dmg", + "arch": [ + "universal" + ] + }, "identity": null, - "artifactName": "ReticulumMeshChat-v${version}-${os}.${ext}", + "artifactName": "ReticulumMeshChat-v${version}-${os}-${arch}.${ext}", "extendInfo": { "NSMicrophoneUsageDescription": "Microphone access is only needed for Audio Calls", "com.apple.security.device.audio-input": true -- 2.49.1 From c95d2fd71c337108eb8d4a3c2ea7549df9c5fa73 Mon Sep 17 00:00:00 2001 From: Sudo-Ivan Date: Fri, 5 Dec 2025 22:01:59 -0600 Subject: [PATCH 2/6] chore: update GitHub Actions workflow for artifact handling and distribution scripts - Changed artifact upload and download actions to specific commit versions for stability. - Introduced new distribution scripts for various platforms in the build configuration. - Updated artifact naming patterns for macOS DMG files to ensure consistency. --- .github/workflows/build.yml | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 22c8e2b..6657362 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -59,7 +59,7 @@ jobs: run: npm run build-frontend - name: Upload frontend artifact - uses: actions/upload-artifact@v4 + uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4 with: name: frontend-build path: meshchatx/public @@ -79,18 +79,21 @@ jobs: python: "3.12" release_artifacts: "dist/*-win-installer.exe,dist/*-win-portable.exe" build_input: build_windows + dist_script: dist-prebuilt - name: mac os: macos-14 node: 18 python: "3.11" release_artifacts: "dist/*-mac-*.dmg" build_input: build_mac + dist_script: dist:mac-universal - name: linux os: ubuntu-latest node: 22 python: "3.12" release_artifacts: "dist/*-linux.AppImage,dist/*-linux.deb,python-dist/*.whl" build_input: build_linux + dist_script: dist-prebuilt permissions: contents: write steps: @@ -150,7 +153,7 @@ jobs: if: | github.event_name == 'push' || (github.event_name == 'workflow_dispatch' && inputs[matrix.build_input] == true) - uses: actions/download-artifact@v4 + uses: actions/download-artifact@d3f86a106a0bac45b974a628896c90dbdf5c8093 # v4 with: name: frontend-build path: meshchatx/public @@ -177,7 +180,7 @@ jobs: if: | github.event_name == 'push' || (github.event_name == 'workflow_dispatch' && inputs[matrix.build_input] == true) - run: npm run dist-prebuilt + run: npm run ${{ matrix.dist_script }} - name: Upload build artifacts if: | @@ -189,7 +192,7 @@ jobs: path: | dist/*-win-installer.exe dist/*-win-portable.exe - dist/*-mac.dmg + dist/*-mac-*.dmg dist/*-linux.AppImage dist/*-linux.deb python-dist/*.whl @@ -204,7 +207,7 @@ jobs: contents: write steps: - name: Download all artifacts - uses: actions/download-artifact@v4 + uses: actions/download-artifact@d3f86a106a0bac45b974a628896c90dbdf5c8093 # v4 with: path: artifacts -- 2.49.1 From d69a3e85225909dc328b6a84025d45a37d79aa13 Mon Sep 17 00:00:00 2001 From: Sudo-Ivan Date: Fri, 5 Dec 2025 22:02:03 -0600 Subject: [PATCH 3/6] chore: update artifact naming for macOS in package.json - Modified the artifactName format to specify 'mac' in the naming convention for clarity and consistency in builds. --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 0da9252..5b02ba2 100644 --- a/package.json +++ b/package.json @@ -45,7 +45,7 @@ ] }, "identity": null, - "artifactName": "ReticulumMeshChat-v${version}-${os}-${arch}.${ext}", + "artifactName": "ReticulumMeshChat-v${version}-mac-${arch}.${ext}", "extendInfo": { "NSMicrophoneUsageDescription": "Microphone access is only needed for Audio Calls", "com.apple.security.device.audio-input": true -- 2.49.1 From 96f4fc87354ed3cdee8a35e26b634f34ce84cf68 Mon Sep 17 00:00:00 2001 From: Sudo-Ivan Date: Fri, 5 Dec 2025 22:12:13 -0600 Subject: [PATCH 4/6] chore: add x64 architecture files for macOS in package.json - Included new x64ArchFiles entry in package.json to specify the path for macOS x64 architecture builds. --- package.json | 3 +++ 1 file changed, 3 insertions(+) diff --git a/package.json b/package.json index 5b02ba2..e544a28 100644 --- a/package.json +++ b/package.json @@ -46,6 +46,9 @@ }, "identity": null, "artifactName": "ReticulumMeshChat-v${version}-mac-${arch}.${ext}", + "x64ArchFiles": [ + "Contents/Resources/app/electron/build/exe/ReticulumMeshChatX" + ], "extendInfo": { "NSMicrophoneUsageDescription": "Microphone access is only needed for Audio Calls", "com.apple.security.device.audio-input": true -- 2.49.1 From 365531be9bcc54af74eb1a2625a9a510e45b7611 Mon Sep 17 00:00:00 2001 From: Sudo-Ivan Date: Fri, 5 Dec 2025 22:33:30 -0600 Subject: [PATCH 5/6] fix: simplify x64ArchFiles entry in package.json - Changed x64ArchFiles from an array to a string for the macOS build path, streamlining the configuration. --- package.json | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/package.json b/package.json index e544a28..1a4b6f9 100644 --- a/package.json +++ b/package.json @@ -46,9 +46,7 @@ }, "identity": null, "artifactName": "ReticulumMeshChat-v${version}-mac-${arch}.${ext}", - "x64ArchFiles": [ - "Contents/Resources/app/electron/build/exe/ReticulumMeshChatX" - ], + "x64ArchFiles": "Contents/Resources/app/electron/build/exe/ReticulumMeshChatX", "extendInfo": { "NSMicrophoneUsageDescription": "Microphone access is only needed for Audio Calls", "com.apple.security.device.audio-input": true -- 2.49.1 From f2ab1ad0670f68492e52f53ad1fde0509ce075c4 Mon Sep 17 00:00:00 2001 From: Sudo-Ivan Date: Fri, 5 Dec 2025 22:37:55 -0600 Subject: [PATCH 6/6] fix: use wildcard path to fix the build for mac --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 1a4b6f9..2e5aa7c 100644 --- a/package.json +++ b/package.json @@ -46,7 +46,7 @@ }, "identity": null, "artifactName": "ReticulumMeshChat-v${version}-mac-${arch}.${ext}", - "x64ArchFiles": "Contents/Resources/app/electron/build/exe/ReticulumMeshChatX", + "x64ArchFiles": "Contents/Resources/app/electron/build/exe/**", "extendInfo": { "NSMicrophoneUsageDescription": "Microphone access is only needed for Audio Calls", "com.apple.security.device.audio-input": true -- 2.49.1