fix(ci): fix release job skipping and pnpm cache issues (#311)

- Add explicit `if` to upload-release job so it isn't skipped when
  validate-tag is skipped (canary branch triggers workflow_dispatch)
- Bust pnpm cache key prefix (pnpm- → pnpm-store-) to avoid
  deserialization failures from old actions/cache v3/v4 entries
- Allow cache saves on workflow_dispatch in addition to push
- Add missing cache/save step to build-linux-arm action

Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Philip Peterson 2026-05-28 18:27:37 -07:00 committed by GitHub
parent b23f9b39a4
commit 65b3f43550
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 13 additions and 6 deletions

View file

@ -49,9 +49,9 @@ runs:
- uses: actions/cache/restore@v5.0.5
with:
path: ${{ steps.pnpm-store-dir-path.outputs.dir }}
key: ${{ runner.os }}-pnpm-${{ hashFiles('pnpm-lock.yaml', 'app/pnpm-lock.yaml') }}
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('pnpm-lock.yaml', 'app/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-pnpm-
${{ runner.os }}-pnpm-store-
- name: Delete old electron headers
# These can sometimes be present on a freshly-provisioned github runner, so remove them
@ -131,6 +131,12 @@ runs:
dist/*.rpm
dist/*.pacman
- uses: actions/cache/save@v5.0.5
if: github.event_name != 'pull_request'
with:
path: ${{ steps.pnpm-store-dir-path.outputs.dir }}
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('pnpm-lock.yaml', 'app/pnpm-lock.yaml') }}
# - name: Run E2E Tests on Linux
# if: runner.os == 'Linux'
# shell: bash

View file

@ -50,9 +50,9 @@ runs:
- uses: actions/cache/restore@v5.0.5
with:
path: ${{ steps.pnpm-store-dir-path.outputs.dir }}
key: ${{ runner.os }}-pnpm-${{ hashFiles('pnpm-lock.yaml', 'app/pnpm-lock.yaml') }}
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('pnpm-lock.yaml', 'app/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-pnpm-
${{ runner.os }}-pnpm-store-
- name: Delete old electron headers
# These can sometimes be present on a freshly-provisioned github runner, so remove them
@ -155,7 +155,7 @@ runs:
path: ./pr_num.txt
- uses: actions/cache/save@v5.0.5
if: github.event_name == 'push'
if: github.event_name != 'pull_request'
with:
path: ${{ steps.pnpm-store-dir-path.outputs.dir }}
key: ${{ runner.os }}-pnpm-${{ hashFiles('pnpm-lock.yaml', 'app/pnpm-lock.yaml') }}
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('pnpm-lock.yaml', 'app/pnpm-lock.yaml') }}

View file

@ -148,6 +148,7 @@ jobs:
- build
- build-linux-armv7l
- build-linux-arm64
if: always() && !contains(needs.*.result, 'failure') && !contains(needs.*.result, 'cancelled') && !contains(needs.*.result, 'skipped')
runs-on: ubuntu-latest
steps:
- name: Download all artifacts