Skip to content

Commit

Permalink
ci: allow opt-out of changelog lint for internal changes
Browse files Browse the repository at this point in the history
We introduced a lint in #4620 that ensures the changelog is updated when we touch a certain crate. This however leads to many "false-positives" where a change to the source code is not actually worth mentioning in the changelog.

To opt out of this change, this patch adds a condition to the job that checks for a `internal:$crate` label and if that is applied, it doesn't run the lint.

Pull-Request: #4673.
  • Loading branch information
thomaseizinger authored Oct 17, 2023
1 parent 21c7ee8 commit f12e015
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
3 changes: 2 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,8 @@ jobs:
!startsWith(github.event.pull_request.title, 'chore') &&
!startsWith(github.event.pull_request.title, 'refactor') &&
!startsWith(github.event.pull_request.title, 'deps') &&
!startsWith(github.event.pull_request.title, 'docs')
!startsWith(github.event.pull_request.title, 'docs') &&
!contains(github.event.pull_request.labels.*.name, 'internal-change')
run: |
git fetch origin master:master
./scripts/ensure-version-bump-and-changelog.sh
Expand Down
8 changes: 8 additions & 0 deletions docs/maintainer-handbook.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,14 @@ Once a PR fulfills all merge requirements (approvals, passing CI, etc), applying
In case of a trivial code change, maintainers may choose to apply the `trivial` label.
This will have mergify approve your PR, thus fulfilling all requirements to automatically queue a PR for merging.

## Changelog entries

Our CI checks that each crate which is modified gets a changelog entry.
Whilst this is a good default safety-wise, it creates a lot of false-positives for changes that are internal and don't need a changelog entry.

For PRs that in the categories `chore`, `deps`, `refactor` and `docs`, this check is disabled automatically.
Any other PR needs to explicitly disable this check if desired by applying the `internal-change` label.

## Dependencies

We version our `Cargo.lock` file for better visibility into which dependencies are required for a functional build.
Expand Down

0 comments on commit f12e015

Please sign in to comment.