gren changelog vs gren changelog --generate inconsistency
After fiddling with the PRs for #140, I came across something that might be an inconsistency in the code.
Running:
gren changelog --include-messages=all --override
Generates CHANGELOG.md (with all releases) these lines (before the fix):
## v1.1.0-beta.0 (01/03/2018)
- [1.1.0-beta.0](https://api.github.com/...) - Author Authorson
After changing the template in the global scope for templateCommits, I rerun:
gren changelog --include-messages=all --override
Providing the same result. Which has not the updated URLs.
But if I run:
gren changelog --include-messages=all --override --generate
I get the CHANGELOG.md with the updated template:
## v1.1.0-beta.0 (01/03/2018)
- [1.1.0-beta.0](https://github.com/...) - Author Authorson
Is this intended, or a bug?
The gren changelog command gets the releases body from the existing ones online, therefore the other options related to the "generating releases" won't be used.
If you want to generate the changelog from scratch, you can use --generate and use all the options from the release command.
Maybe isn't clear enough?
Ah, no you misunderstand, the issue is not whether or not the number of releases are one or more, it's that gren some how caches between usage of gren changelog and gren changelog --generate.
After I applied the fix for #140 , I ran gren changelog, expecting the urls in CHANGELOG.md to be the correct one, but it was still pointing to https://api.github.com/. The only way I could force gren to use the new and correct url was with gren changelog --generate, producing the correct urls, starting with https://github.com/
Ohhhh! I see now!
Ok good point! Thanks 😄