Skip to content

Commit

Permalink
Validate changelog only in PRs targeting main
Browse files Browse the repository at this point in the history
Prevent validate-changelog workflow from failing on main
Avoid unnecessary checks on intermediary branches
  • Loading branch information
MattiSG committed Jul 11, 2024
1 parent 9ced530 commit 4eccec2
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions .github/workflows/changelog.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ on:

jobs:
validate-changelog:
if: github.base_ref == 'main' || github.base_ref == 'test-main' # check that changelog has valid unreleased changes only in PRs that could trigger a release
runs-on: [ ubuntu-latest ]
outputs:
release-type: ${{ steps.validate-changelog.outputs.release-type }}
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ jobs:
with:
token: ${{ secrets.RELEASE_BOT_GITHUB_TOKEN }}
branch: main
acceptable_conclusions: 'success,skipped' # changelog checks are skipped when not in a PR towards main branch
tags: true
interval: 10 # seconds between checks
pre_sleep: 15
Expand Down

0 comments on commit 4eccec2

Please sign in to comment.