Skip to content

Add new capabilities to cz version #1677

@woile

Description

@woile

Description

The idea of this ticket is to track the "graduation" of cz version --project into a powerful command, capable of fetching information about the project.

This includes:

  • Introduce --next flag on cz version --project. Which returns the next version based on the project's config. It could potentially support forcing the increment type. Example: --next=MAJOR or --next=PATCH Introduce --next flag on cz version --project #1678
  • Allow users to play with the configured version_scheme, by letting them provide any version, cz version <version_arg>, this would override the commitizen version or the given --project parameter. The user would then be able to "learn" about the behavior, by doing cz version 0.1.0 --next=MAJOR Add support for cz version <version_arg> #1679
  • Add --tag: to actually retrieve the tag of the version with the template applied. If your tags looks like this: v0.1.0. You have to manually add v to your version right now. This would be useful to interact with git. If you want to retrieve the tagged commit, you could do: git show-ref $(cz version -p --tag). This is useful for auditing. And, if you have an old CI (e.g: jenkins), it would give an easy way for teams to check if the tag exists already before trying to bump. This parameter is the one I'm least sure about, so maybe we can work on the other features first, and if we think it would be useful, we add it.
  • Do we want a --hash to get the version hash for auditing purposes?

#1640

Sub-issues

Metadata

Metadata

Assignees

No one assigned

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions