Skip to content

Commit

Permalink
chore: fix broken action
Browse files Browse the repository at this point in the history
  • Loading branch information
Aireil committed Nov 15, 2024
1 parent f86174f commit 808556a
Showing 1 changed file with 11 additions and 8 deletions.
19 changes: 11 additions & 8 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,14 +29,17 @@ jobs:
- name: Extract Branch
id: extract_branch
run: |
$branch_name = 'main'
$commit_messages = (echo "${{ toJSON(github.event.commits.*.message) }}")
if ($commit_messages -match 'build\(([^)]+)\):') {
$branch_name = $matches[1]
}
echo "branch_name=$branch_name" >> $GITHUB_OUTPUT
$branch_name = 'main'
$commit_messages = ${{ github.event.commits }}
foreach ($commit in $commit_messages) {
if ($commit.message -match 'build\(([^)]+)\):') {
$branch_name = $matches[1]
break
}
}
echo "branch_name=$branch_name" >> $GITHUB_OUTPUT
- name: Setup MSBuild
uses: microsoft/[email protected]
Expand Down

0 comments on commit 808556a

Please sign in to comment.