Skip to content

Commit df3f986

Browse files
Copilotchefgs
andcommitted
Fix: use inputs.branch in checkout and guard head_commit.message for workflow_dispatch
Agent-Logs-Url: https://github.com/cloudengine-labs/devops_os/sessions/173bdd11-b657-4dcd-8aa5-d0306d8fc88d Co-authored-by: chefgs <7605658+chefgs@users.noreply.github.com>
1 parent 126af43 commit df3f986

1 file changed

Lines changed: 4 additions & 3 deletions

File tree

.github/workflows/release.yml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,16 +26,17 @@ jobs:
2626
# references the release/vX.Y.Z branch name.
2727
if: >-
2828
github.actor != 'github-actions[bot]' &&
29-
!contains(github.event.head_commit.message, '[skip ci]') &&
30-
!(startsWith(github.event.head_commit.message, 'Merge pull request') &&
31-
contains(github.event.head_commit.message, 'release/v'))
29+
!contains(github.event.head_commit.message || '', '[skip ci]') &&
30+
!(startsWith(github.event.head_commit.message || '', 'Merge pull request') &&
31+
contains(github.event.head_commit.message || '', 'release/v'))
3232
3333
steps:
3434
- name: Checkout repository (full history for tagging)
3535
uses: actions/checkout@v4
3636
with:
3737
token: ${{ secrets.GITHUB_TOKEN }}
3838
fetch-depth: 0
39+
ref: ${{ inputs.branch }}
3940

4041
- name: Set up Python
4142
uses: actions/setup-python@v5

0 commit comments

Comments
 (0)