Skip to content
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

Add new ## Unreleased section to CHANGELOG.md after replacing it with the just-released tag #415

Open
vaind opened this issue Sep 14, 2022 · 8 comments

Comments

@vaind
Copy link
Contributor

vaind commented Sep 14, 2022

This is something everyone has to do manually at the moment (or have some other automation do it for them).

I guess this could be an additional commit after the tagged change.

@asottile-sentry
Copy link
Member

could you elaborate on what you're referring to ?

@vaind
Copy link
Contributor Author

vaind commented Sep 14, 2022

After this commit is made, I'd like there to be another one that adds a blank ## Unreleased section to the changelog.

@vaind vaind changed the title Add new ## Unreleased section after replacing it with the just-released tag Add new ## Unreleased section to CHANGELOG.md after replacing it with the just-released tag Sep 14, 2022
@asottile-sentry
Copy link
Member

I'm not sure how that would work -- wouldn't that make the top of a just-released changelog say "Unreleased" if it were to add that section at the same time ? that seems undesirable

@vaind
Copy link
Contributor Author

vaind commented Sep 14, 2022

Yes, it would - that's what the changelog.md looks like anyway - PRs add their items to the Unreleased section, then there's a release which just renames it. The first contributor that comes with a PR after a release needs to update their changelog by adding the Unreleased section first.

I mean it's really a first-world-problem of course, just nice to have as it makes life just a bit easier. Also, it helps reduce the chance (of course it doesn't prevent this) of accidentally adding one to an already released section accidentally.

examples:
image
image

@asottile-sentry
Copy link
Member

I think what you actually want is a post-release commit to re-add that section -- having it be part of the release will ship that "Unreleased" header to package repositories

@vaind
Copy link
Contributor Author

vaind commented Sep 14, 2022

I think what you actually want is a post-release commit to re-add that section

yes exactly

having it be part of the release will ship that "Unreleased" header to package repositories

Maybe my assumption was wrong then - I thought craft runs the whole release process so it could make a commit after it made the release?

@asottile-sentry
Copy link
Member

the current way craft works is it merges in a commit that's already passed tests -- it could add another commit afterwards but I'm not sure it should without review / passing tests / etc.

@BYK
Copy link
Contributor

BYK commented Sep 14, 2022

Why not use the automatic changelog policy instead?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants