refactor(build): avoid release publishing race conditions

Only run release jobs after all build jobs have completed, ensure only
one release job runs at a time, and also ensure update casks only runs
once after all release jobs have completed.
This commit is contained in:
2024-11-03 14:45:37 +00:00
parent e0c0d92424
commit 099c10776a
5 changed files with 117 additions and 39 deletions

27
.github/workflows/_update-casks.yml vendored Normal file
View File

@@ -0,0 +1,27 @@
---
name: _update-casks
concurrency:
group: _update-casks
cancel-in-progress: false
on:
workflow_call:
inputs:
os:
description: GitHub Actions runner OS
type: string
required: false
default: "ubuntu-latest"
secrets:
TAP_REPO_TOKEN:
description: Personal Access Token for Homebrew Tap repo
required: true
jobs:
emacs-builds:
runs-on: ${{ inputs.os }}
steps:
- name: Trigger update casks workflow in homebrew tap
run: >-
gh workflow run --repo jimeh/homebrew-emacs-builds update-casks.yml
env:
GITHUB_TOKEN: ${{ secrets.TAP_REPO_TOKEN }}