actions-marketplace-validations/Git Semantic Version
Determines version of a repo based on git history
View on GitHubTrust Signals
- Scorecard Score
- not yet scored
- Maintenance Recency
- Activelast commit Mar 17, 2026
- License
- MIT
Pinned Snippet
uses: actions-marketplace-validations/paulhatch_semantic-version@9f72830310d5ed81233b641ee59253644cd8a8fc # no releases — HEAD as of 2026-07-10tags can be moved; commit SHAs can't. why a SHA?
Inputs
| name | description | required | default |
|---|---|---|---|
| branch | Set to specify a specific branch, default is the current HEAD | yes | HEAD |
| tag_prefix | The prefix to use to identify tags | no | v |
| use_branches | (Deprecated) Use branches instead of tags | no | false |
| version_from_branch | If true, the branch will be used to select the maximum version | no | false |
| major_pattern | A string which, if present in a git commit, indicates that a change represents a major (breaking) change. Wrap with '/' to match using a regular expression. | yes | /!:|BREAKING CHANGE:/ |
| major_regexp_flags | A string which indicates the flags used by the `major_pattern` regular expression. Supported flags: idgs | no | "" |
| minor_pattern | A string which, if present in a git commit, indicates that a change represents a minor (feature) change. Wrap with '/' to match using a regular expression. | yes | /feat(\(.+\))?:/ |
| minor_regexp_flags | A string which indicates the flags used by the `minor_pattern` regular expression. Supported flags: idgs | no | "" |
| ignore_commits_pattern | A pattern to match commits that should be ignored when calculating the version. Commits matching this pattern will not trigger any version bump. Wrap with '/' to use a regular expression. | no | "" |
| version_format | Pattern to use when formatting output version | yes | ${major}.${minor}.${patch} |
| change_path | Path to check for changes. If any changes are detected in the path the 'changed' output will true. Enter multiple paths separated by spaces. | no | — |
| namespace | Use to create a named sub-version. This value will be appended to tags created for this version. | no | — |
| bump_each_commit | If true, every commit will be treated as a bump to the version. | yes | false |
| search_commit_body | If true, the body of commits will also be searched for major/minor patterns to determine the version type. | yes | false |
| user_format_type | The output method used to generate list of users, 'csv' or 'json'. Default is 'csv'. | yes | csv |
| enable_prerelease_mode | Prevents pre-v1.0.0 version from automatically incrementing the major version. If enabled, when the major version is 0, major releases will be treated as minor and minor as patch. Note that the version_type output is unchanged. | yes | false |
| bump_each_commit_patch_pattern | If bump_each_commit is also set to true, setting this value will cause the version to increment only if the pattern specified is matched. | yes | "" |
| debug | If enabled, diagnostic information will be added to the action output | yes | false |
Outputs
| name | description |
|---|---|
| major | Current major number |
| minor | Current minor number |
| patch | Current patch number |
| increment | An additional value indicating the number of commits for the current version |
| version_type | Indicates the type of change this version represents vs the previous, e.g. 'major', 'minor', 'patch', or 'none' |
| version | The version result, in the format {major}.{minor}.{patch} |
| version_tag | The version tag |
| changed | Indicates whether there was a change since the last version if change_path was specified. If no change_path was specified this value will always be true since the entire repo is considered. |
| is_tagged | Indicates that the commit had a tag that matched the 'versionTag' format |
| authors | List of users contributing commits to this version |
| previous_commit | Hash of the previous commit |
| previous_version | Indicates the previous version |
| current_commit | The current commit hash |
| debug_output | Diagnostic information, if debug is enabled |