-
-
Notifications
You must be signed in to change notification settings - Fork 140
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
chore(release): generate changelogs with git-cliff
#416
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
hawkw
added a commit
that referenced
this pull request
Sep 29, 2023
We maintain separate changelogs for the `tokio-console`, `console-api`, and `console-subscriber` crates. Currently, changelogs are generated using the [`clog`] CLI tool. However, `clog` does not support generating separate changelogs for different subdirectories of a repo, so the current release process for a given crate requires generating a changelog for the whole repo since the last tag, and then manually editing it to remove changes to other crates. This is a pain. The [`git-cliff`] changelog-generating tool supports generating a changelog that only includes commits that modified specific paths in the repo. This means it can be used to generate separate changelogs for each crate automatically, unlike `clog`. It's also much more configurable, and we can use it to generate changelogs that have somewhat nicer formatting (IMO). This branch changes changelog generation from using `clog` to use `git-cliff`, and regenerates all the existing changelogs. The included `bin/update-changelog.sh` shell script updates the changelog for a given crate to the provided tag. This will make the release process much less complicated. A subsequent PR will add a shell script that handles updating crate versions, generating the changelog, and publishing the crate and tag, so that a release can be published by running a single command. [`clog`]: https://github.com/clog-tool/clog-cli [`git-cliff`]: https://git-cliff.org/
hds
added a commit
that referenced
this pull request
Apr 12, 2024
Releasing the console crates has been a bit of a hassle. It requires manual work run locally and as such, we have gone long periods without releases, despite having changes which would be worth releasing. [Release-plz] provides release automation based on GitHub actions. It will create, and then update a PR for the next release. Release-plz depends on [conventional commits] (which the `console` project is already following) to determine the next version number for each crate and then uses [cargo-semver-checks] to check that the version bump is correct. For the changelogs, [git-cliff] is used. Since we already started using in #416, so we can reuse our existing `cliff.toml` config file. A small change has been made to remove the footer, as it was getting included multiple times in a single changelog file due to the delta updates. **Caution**: In order to use Release-plz, a crates.io token first needs to be added to the GitHub project. This means that anyone with PR merge rights will be able to run a release by merging the Release PR. Additionally, GitHub actions need to be given permission to create PRs. [Release-plz]: https://release-plz.ieni.dev/ [conventional commits]: https://www.conventionalcommits.org/en/v1.0.0/ [cargo-semver-checks]: https://github.com/obi1kenobi/cargo-semver-checks [git-cliff]: https://git-cliff.org/
hds
added a commit
that referenced
this pull request
Apr 12, 2024
Releasing the console crates has been a bit of a hassle. It requires manual work run locally and as such, we have gone long periods without releases, despite having changes which would be worth releasing. [Release-plz] provides release automation based on GitHub actions. It will create, and then update a PR for the next release. Release-plz depends on [conventional commits] (which the `console` project is already following) to determine the next version number for each crate and then uses [cargo-semver-checks] to check that the version bump is correct. For the changelogs, [git-cliff] is used. Since we already started using in #416, so we can reuse our existing `cliff.toml` config file. A small change has been made to remove the footer, as it was getting included multiple times in a single changelog file due to the delta updates. **Caution**: In order to use Release-plz, a crates.io token first needs to be added to the GitHub project. This means that anyone with PR merge rights will be able to run a release by merging the Release PR. Additionally, GitHub actions need to be given permission to create PRs. The previous scripts used to release have been removed. [Release-plz]: https://release-plz.ieni.dev/ [conventional commits]: https://www.conventionalcommits.org/en/v1.0.0/ [cargo-semver-checks]: https://github.com/obi1kenobi/cargo-semver-checks [git-cliff]: https://git-cliff.org/
hds
added a commit
that referenced
this pull request
Jun 7, 2024
Releasing the console crates has been a bit of a hassle. It requires manual work run locally and as such, we have gone long periods without releases, despite having changes which would be worth releasing. [Release-plz] provides release automation based on GitHub actions. It will create, and then update a PR for the next release. Release-plz depends on [conventional commits] (which the `console` project is already following) to determine the next version number for each crate and then uses [cargo-semver-checks] to check that the version bump is correct. For the changelogs, [git-cliff] is used. Since we already started using in #416, so we can reuse our existing `cliff.toml` config file. A small change has been made to remove the footer, as it was getting included multiple times in a single changelog file due to the delta updates. **Caution**: In order to use Release-plz, a crates.io token first needs to be added to the GitHub project. This means that anyone with PR merge rights will be able to run a release by merging the Release PR. Additionally, GitHub actions need to be given permission to create PRs. The previous scripts used to release have been removed. [Release-plz]: https://release-plz.ieni.dev/ [conventional commits]: https://www.conventionalcommits.org/en/v1.0.0/ [cargo-semver-checks]: https://github.com/obi1kenobi/cargo-semver-checks [git-cliff]: https://git-cliff.org/
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
We maintain separate changelogs for the
tokio-console
,console-api
,and
console-subscriber
crates.Currently, changelogs are generated using the
clog
CLI tool.However,
clog
does not support generating separate changelogs fordifferent subdirectories of a repo, so the current release process for a
given crate requires generating a changelog for the whole repo since the
last tag, and then manually editing it to remove changes to other
crates. This is a pain.
The
git-cliff
changelog-generating tool supports generating achangelog that only includes commits that modified specific paths in the
repo. This means it can be used to generate separate changelogs for each
crate automatically, unlike
clog
. It's also much more configurable,and we can use it to generate changelogs that have somewhat nicer
formatting (IMO).
This branch changes changelog generation from using
clog
to usegit-cliff
, and regenerates all the existing changelogs. The includedbin/update-changelog.sh
shell script updates the changelog for a givencrate to the provided tag. This will make the release process much less
complicated.
A subsequent PR will add a shell script that handles updating crate
versions, generating the changelog, and publishing the crate and tag, so
that a release can be published by running a single command.