(conventional-recommended-bump) Specify base tag to analyze tags from #777
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.
This feature allows the user to specify the base tag from which to scan for version tags, allowing for tooling like standard-version to pull the previous version from some other location than the most recent tag. As simple icing I added the flag to the both the recommended-bump and changelog CLIs so that users of those tools can enjoy this feature there as well.
I chose not to attempt a "to" flag as that would make this much more complex and is not needed for my use case just now.
Also fixes a bug in conventional-recommended-bump that would cause a callback to not be called if the
gitRawCommits
function emitted an error instead of returning a stream.AFAICT this could be a fix for both #194 and #612, but this was mainly to solve a problem in standard-version. I'll link the PR to that repo once I've got it created.
In my use-case I don't store the changelog in the committed code as it has problems when dealing with branches. I don't see any generic way to solve that problem, so instead I use my own repo-specific algorithm to determine which tag in the history is the "correct" parent tag depending on several bits of repo-specific context and then need to generate the changelog and recommended bump based off that tag, and not before.