Skip to content

Commit a162094

Browse files
author
Paul Hatcher
committed
Introduce CustomVersion and custom-version-format
1 parent b99178e commit a162094

23 files changed

+711
-19
lines changed

docs/input/docs/reference/configuration.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -519,6 +519,12 @@ Specifies the format of `AssemblyInformationalVersion`.
519519
Follows the same formatting semantics as `assembly-file-versioning-format`.
520520
The default value is `{InformationalVersion}`.
521521

522+
### custom-version-format
523+
524+
Specifies the format of `CustomVersion`.
525+
Follows the same formatting semantics as `assembly-file-versioning-format`.
526+
The default value is `{SemVer}`.
527+
522528
### mode
523529

524530
Sets the `mode` of how GitVersion should create a new version. Read more at

docs/input/docs/reference/variables.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ what is available. For the `release/3.0.0` branch of GitVersion it shows:
2727
"AssemblySemVer": "3.22.11.0",
2828
"AssemblySemFileVer": "3.22.11.0",
2929
"InformationalVersion": "3.22.11-beta.99+88.Branch.release/3.022.011.Sha.28c853159a46b5a87e6cc9c4f6e940c59d6bc68a",
30+
"CustomVersion": "3.22.11-beta.99",
3031
"FullSemVer": "3.22.11-beta.99+88",
3132
"BranchName": "release/3.022.011",
3233
"EscapedBranchName": "release-3.022.011",
@@ -59,6 +60,7 @@ Each property of the above JSON document is described in the below table.
5960
| `AssemblySemVer` | Suitable for .NET `AssemblyVersion`. Defaults to `Major.Minor.0.0` to allow the assembly to be hotfixed without breaking existing applications that may be referencing it. |
6061
| `AssemblySemFileVer` | Suitable for .NET `AssemblyFileVersion`. Defaults to `Major.Minor.Patch.0`. |
6162
| `InformationalVersion` | Suitable for .NET `AssemblyInformationalVersion`. Defaults to `FullSemVer` suffixed by `FullBuildMetaData`. |
63+
| `CustomVersion` | The custom version, suitable for package managers with formatting changes, e.g. NuGet. Defaults to `SemVer`. |
6264
| `FullSemVer` | The full, SemVer 2.0 compliant version number. |
6365
| `BranchName` | The name of the checked out Git branch. |
6466
| `EscapedBranchName` | Equal to `BranchName`, but with `/` replaced with `-`. |

docs/input/docs/usage/cli/arguments.md

Lines changed: 18 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -114,23 +114,24 @@ Double quote character inside of the double quoted `value` has to be be escaped
114114
Following options are supported:
115115
116116
1. `assembly-file-versioning-format`
117-
2. `assembly-file-versioning-scheme`
118-
3. `assembly-informational-format`
119-
4. `assembly-versioning-format`
120-
5. `assembly-versioning-scheme`
121-
6. `commit-date-format`
122-
7. `commit-message-incrementing`
123-
8. `label`
124-
9. `increment`
125-
10. `major-version-bump-message`
126-
11. `minor-version-bump-message`
127-
12. `mode`
128-
13. `next-version`
129-
14. `no-bump-message`
130-
15. `patch-version-bump-message`
131-
16. `tag-prefix`
132-
17. `tag-pre-release-weight`
133-
18. `update-build-number`
117+
1. `assembly-file-versioning-scheme`
118+
1. `assembly-informational-format`
119+
1. `assembly-versioning-format`
120+
1. `assembly-versioning-scheme`
121+
1. `commit-date-format`
122+
1. `commit-message-incrementing`
123+
1. `custom-version-format`
124+
1. `label`
125+
1. `increment`
126+
1. `major-version-bump-message`
127+
1. `minor-version-bump-message`
128+
1. `mode`
129+
1. `next-version`
130+
1. `no-bump-message`
131+
1. `patch-version-bump-message`
132+
1. `tag-prefix`
133+
1. `tag-pre-release-weight`
134+
1. `update-build-number`
134135
135136
Read more about [Configuration](/docs/reference/configuration).
136137

0 commit comments

Comments
 (0)