Skip to content

Commit

Permalink
fix(gha): fix branch detection error (#4844)
Browse files Browse the repository at this point in the history
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)
  • Loading branch information
dbyron-sf authored Feb 19, 2025
1 parent d66c0c2 commit effb8b6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
# Given a tag, determine what branch we are on, so we can bump dependencies in the correct branch
- name: Get Branch
run: |
BRANCHES=$(git branch -r --contains ${{ github.ref }})
BRANCHES=$(git branch -r --contains ${{ github.ref }} | grep -v 'HEAD')
echo "BRANCHES is '${BRANCHES}'"
# Check for no branches explicitly...Otherwise echo adds a newline so wc thinks there's
# one branch. And echo -n makes it appears that there's one less branch than there
Expand Down

0 comments on commit effb8b6

Please sign in to comment.