Skip to content

Commit b73651d

Browse files
committed
Replace GitVersion.yaml with a more forgiving version
1 parent e7c8428 commit b73651d

File tree

1 file changed

+40
-13
lines changed

1 file changed

+40
-13
lines changed

GitVersion.yml

Lines changed: 40 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,46 @@
1-
mode: Mainline
2-
assembly-versioning-format: '{Major}.{Minor}.{Patch}.{env:BUILDCOUNT ?? 0}'
3-
assembly-informational-format: '{NuGetVersionV2}+Build.{env:BUILDCOUNT ?? 0}.Date.{CommitDate}.Branch.{env:SAFEBRANCHNAME ?? unknown}.Sha.{Sha}'
4-
major-version-bump-message: '\+?semver:\s?(breaking|major)'
5-
minor-version-bump-message: '\+?semver:\s?(feature|minor)'
6-
patch-version-bump-message: '\+?semver:\s?(fix|patch)'
7-
no-bump-message: '\+?semver:\s?(none|skip)'
1+
mode: mainline
2+
commit-date-format: "yyyyMMddTHHmmss"
3+
assembly-file-versioning-format: "{Major}.{Minor}.{Patch}.{env:GITHUB_RUN_NUMBER ?? 0}"
4+
5+
# This repo needs to use NuGetVersionV2 for compatibility with PowerShellGallery
6+
assembly-informational-format: "{NuGetVersionV2}+Build.{env:GITHUB_RUN_NUMBER ?? local}.Branch.{EscapedBranchName}.Sha.{Sha}.Date.{CommitDate}"
7+
major-version-bump-message: 'semver:\s?(breaking|major)'
8+
minor-version-bump-message: 'semver:\s?(feature|minor)'
9+
patch-version-bump-message: 'semver:\s?(fix|patch)'
10+
no-bump-message: 'semver:\s?(none|skip)'
11+
commit-message-incrementing: Enabled
12+
813
branches:
9-
master:
14+
main:
15+
tag: "" # explicitly no tag for main builds
16+
regex: ^main$
1017
increment: Patch
11-
pull-request:
18+
is-mainline: true
19+
tracks-release-branches: true
20+
hotfix:
21+
tag: rc
22+
regex: hotfix(es)?/\d+\.\d+\.\d+
23+
increment: None
24+
is-release-branch: true
25+
prevent-increment-of-merged-branch-version: true
26+
source-branches: [ "main" ]
27+
release:
1228
tag: rc
29+
regex: releases?/\d+\.\d+\.\d+
30+
increment: None
31+
is-release-branch: true
32+
prevent-increment-of-merged-branch-version: true
33+
source-branches: [ "main" ]
34+
pull-request:
35+
regex: pull/
36+
tag: pr
37+
tag-number-pattern: '[/-](?<number>\d+)'
1338
increment: Patch
39+
source-branches: [ "main", "feature", "release", "hotfix" ]
1440
feature:
41+
regex: .*/
42+
tag: useBranchName
43+
source-branches: [ "main", "feature" ]
44+
track-merge-target: true
45+
tracks-release-branches: true
1546
increment: Patch
16-
regex: .*?/
17-
source-branches:
18-
- master
19-
- feature

0 commit comments

Comments
 (0)