github-changelog-generator
github-changelog-generator copied to clipboard
Do not overwrite human-readable changes to old versions
This might be best left to external scripts, but I'm interested to see how people feel about it.
My ideal workflow would be:
- To run
github-changelog-generator
on every merge intomaster
as an automatic commit. - Directly commit human-readable changes to
CHANGELOG.md
inmaster
. - Repeat.
Problem right now is that the human-readable changelogs would be overwritten by step 1. The idea of this feature request is to only add changes to the CHANGELOG.md
file in versions that are older than the latest found tag.
An external script can do this:
- Parse the
CHANGELOG.md
file using regex (or by creating a Markdown AST) and collect a file containing all of the sections of versions that have tags. - Create a
HISTORY.md
file using step 1's output. - Run
github-changelog-generator
. It will pullHISTORY.md
by concatenating to the end of the file. - Delete
HISTORY.md
(optional).
Any thoughts on this? Thanks!
I wrote a GitHub Action that does this (and other stuff) here.