Skip to content
This repository was archived by the owner on Oct 2, 2025. It is now read-only.

Commit effb8b6

Browse files
authored
fix(gha): fix branch detection error (#4844)
from e.g. https://github.com/spinnaker/orca/actions/runs/13415978286/job/37476832943 Run BRANCHES=$(git branch -r --contains refs/tags/v8.60.0) BRANCHES is ' origin/HEAD -> origin/master origin/master' NUM_BRANCHES is '2' exactly one branch required to release orca, but there are 2 ( origin/HEAD -> origin/master origin/master)
1 parent d66c0c2 commit effb8b6

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

.github/workflows/release.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ jobs:
2020
# Given a tag, determine what branch we are on, so we can bump dependencies in the correct branch
2121
- name: Get Branch
2222
run: |
23-
BRANCHES=$(git branch -r --contains ${{ github.ref }})
23+
BRANCHES=$(git branch -r --contains ${{ github.ref }} | grep -v 'HEAD')
2424
echo "BRANCHES is '${BRANCHES}'"
2525
# Check for no branches explicitly...Otherwise echo adds a newline so wc thinks there's
2626
# one branch. And echo -n makes it appears that there's one less branch than there

0 commit comments

Comments
 (0)