Problem
All three workflow files hardcode ReduxAPI_GUI as the branch name in their on: trigger filters:
.github/workflows/code-analysis.yml — push and pull_request filters (lines 17–18)
.github/workflows/main.yml — pull_request filter
.github/workflows/publish.yml — push filter
If the default branch is ever renamed, these workflows will silently stop triggering on push and pull_request events to the new default branch.
Fix
Replace the hardcoded ReduxAPI_GUI with GitHub's $default-branch token in each branches: filter:
on:
push:
branches: [ $default-branch ]
pull_request:
branches: [ $default-branch ]
$default-branch is a GitHub-recognized token in branches: filters that resolves to whatever the repository's current default branch is set to. This makes the workflows resilient to future branch renames without any further changes.
Why now
The Redux project is considering renaming default branches across its repositories. Updating the workflows first (or alongside the rename) avoids a window where CI stops running on the new default branch.
See also: ReduxISU/Redux#295 for the same change in the backend repo.
Problem
All three workflow files hardcode
ReduxAPI_GUIas the branch name in theiron:trigger filters:.github/workflows/code-analysis.yml—pushandpull_requestfilters (lines 17–18).github/workflows/main.yml—pull_requestfilter.github/workflows/publish.yml—pushfilterIf the default branch is ever renamed, these workflows will silently stop triggering on push and pull_request events to the new default branch.
Fix
Replace the hardcoded
ReduxAPI_GUIwith GitHub's$default-branchtoken in eachbranches:filter:$default-branchis a GitHub-recognized token inbranches:filters that resolves to whatever the repository's current default branch is set to. This makes the workflows resilient to future branch renames without any further changes.Why now
The Redux project is considering renaming default branches across its repositories. Updating the workflows first (or alongside the rename) avoids a window where CI stops running on the new default branch.
See also: ReduxISU/Redux#295 for the same change in the backend repo.