fix(desktop): prevent updates to unsupported macOS versions (#12115)
This commit is contained in:
@@ -292,6 +292,13 @@ jobs:
|
||||
run: node scripts/verify-mac-update-resources.js "$APP_PATH"
|
||||
working-directory: ui/desktop
|
||||
|
||||
- name: Record macOS update requirements
|
||||
env:
|
||||
APP_PATH: ${{ inputs.target == 'x86_64-apple-darwin' && 'out/Goose-darwin-x64/Goose.app' || 'out/Goose-darwin-arm64/Goose.app' }}
|
||||
METADATA_PATH: ${{ inputs.target == 'x86_64-apple-darwin' && 'out/Goose-darwin-x64/Goose_intel_mac.zip.macos.json' || 'out/Goose-darwin-arm64/Goose.zip.macos.json' }}
|
||||
run: node scripts/mac-update-requirements.js "$APP_PATH" "$METADATA_PATH"
|
||||
working-directory: ui/desktop
|
||||
|
||||
- name: Clean up signing keychain
|
||||
if: always()
|
||||
run: |
|
||||
@@ -309,7 +316,9 @@ jobs:
|
||||
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
|
||||
with:
|
||||
name: ${{ inputs.target == 'x86_64-apple-darwin' && 'Goose-darwin-x64' || 'Goose-darwin-arm64' }}
|
||||
path: ${{ inputs.target == 'x86_64-apple-darwin' && 'ui/desktop/out/Goose-darwin-x64/Goose_intel_mac.zip' || 'ui/desktop/out/Goose-darwin-arm64/Goose.zip' }}
|
||||
path: |
|
||||
${{ inputs.target == 'x86_64-apple-darwin' && 'ui/desktop/out/Goose-darwin-x64/Goose_intel_mac.zip' || 'ui/desktop/out/Goose-darwin-arm64/Goose.zip' }}
|
||||
${{ inputs.target == 'x86_64-apple-darwin' && 'ui/desktop/out/Goose-darwin-x64/Goose_intel_mac.zip.macos.json' || 'ui/desktop/out/Goose-darwin-arm64/Goose.zip.macos.json' }}
|
||||
if-no-files-found: error
|
||||
overwrite: true
|
||||
|
||||
|
||||
@@ -372,6 +372,10 @@ jobs:
|
||||
run: source ../../bin/activate-hermit && pnpm run test:run
|
||||
working-directory: ui/desktop
|
||||
|
||||
- name: Test macOS update manifests
|
||||
run: source ../../bin/activate-hermit && node --test scripts/mac-update-requirements.test.cjs
|
||||
working-directory: ui/desktop
|
||||
|
||||
desktop-updater-install:
|
||||
name: Test Desktop Updater Install (${{ matrix.os }})
|
||||
runs-on: ${{ matrix.os }}
|
||||
|
||||
@@ -131,7 +131,6 @@ jobs:
|
||||
merge-multiple: true
|
||||
|
||||
- name: Generate macOS update manifest
|
||||
if: ${{ env.ENABLE_MAC_NATIVE_AUTO_UPDATE == 'true' }}
|
||||
run: node ui/desktop/scripts/generate-mac-update-manifest.js --version "${GITHUB_REF_NAME}" --directory .
|
||||
|
||||
- name: Attest macOS update manifest
|
||||
@@ -152,6 +151,7 @@ jobs:
|
||||
*.rpm
|
||||
*.flatpak
|
||||
download_cli.sh
|
||||
mac-update-requirements.json
|
||||
|
||||
# Create/update the versioned release
|
||||
- name: Release versioned
|
||||
@@ -167,6 +167,7 @@ jobs:
|
||||
*.rpm
|
||||
*.flatpak
|
||||
download_cli.sh
|
||||
mac-update-requirements.json
|
||||
allowUpdates: true
|
||||
omitBody: true
|
||||
omitPrereleaseDuringUpdate: true
|
||||
@@ -187,6 +188,7 @@ jobs:
|
||||
*.rpm
|
||||
*.flatpak
|
||||
download_cli.sh
|
||||
mac-update-requirements.json
|
||||
allowUpdates: true
|
||||
omitBody: true
|
||||
omitPrereleaseDuringUpdate: true
|
||||
|
||||
Reference in New Issue
Block a user