Generate a CHANGELOG for your project using only local git history. No internet connection or git server API is required.
$ brew tap neogeek/generate-local-changelog
$ brew install generate-local-changelog
$ generate-local-changelog > CHANGELOG.md
$ generate-local-changelog --unreleased > CHANGELOG.md
$ generate-local-changelog --include-incomplete-merges > CHANGELOG.md
Typically a PR merged from GitHub will look like this:
* c4ca423 (2 minutes ago) Merge pull request #1 from username/repo
|\
| * 8a0b923 (10 minutes ago)
| * 820dcc5 (15 minutes ago)
|/
* 832627b (1 hour ago)
But on occassion a PR can appear like this:
* c4ca423 (2 minutes ago) [feat] PR subject line (#1)
* 8a0b923 (10 minutes ago)
* 820dcc5 (15 minutes ago)
* 832627b (1 hour ago)
Git will not treat these as valid merges and therefore they will be missing from the generated CHANGELOG. To include them, add --include-incomplete-merges
flag. This will of course be different from repo to repo. Only use this flag if you notice PRs missing from your CHANGELOG.