Skip to content

Commit

Permalink
fix(ci): use gh env to skip steps
Browse files Browse the repository at this point in the history
Signed-off-by: Anton Engelhardt <[email protected]>
  • Loading branch information
antonengelhardt committed Jun 5, 2024
1 parent 5b28ab1 commit 8e9d873
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -192,10 +192,12 @@ jobs:
run: |
if git log -1 --pretty=%B | grep -q "chore(release): prepare for"; then
echo "Latest commit is a release commit, exiting..."
echo "EXIT=1" >> $GITHUB_ENV
exit 0
fi
- name: Get most recent merged PR and calculate the next tag
if: env.EXIT != '1'
id: get_pr
run: |
MOST_RECENTLY_MERGED_PR=$(curl -s -H 'Accept: application/vnd.github.v3+json' "https://api.github.com/repos/antonengelhardt/wasm-oidc-plugin/pulls?state=closed" | \
Expand Down Expand Up @@ -264,6 +266,7 @@ jobs:
echo "NEW_TAG=$NEW_TAG" >> $GITHUB_ENV
- name: Create a tag on main
if: env.EXIT != '1'
run: |
git checkout origin/main
Expand Down

0 comments on commit 8e9d873

Please sign in to comment.