Skip to content

Commit 4b5c34a

Browse files
committed
Update GitVersion and build pipeline configurations
Updated `build.yml` to use GitVersion actions `v4.2.0` and `actions/checkout@v4` with `fetch-depth: 0` for full Git history. Configured `GitVersion.yml` with custom commit message patterns for version bumps, enabled `commit-message-incrementing`, and added `update-build-number: true`. Adjusted `assembly-informational-format` and refined `master` branch settings for versioning.
1 parent 96b9790 commit 4b5c34a

2 files changed

Lines changed: 15 additions & 5 deletions

File tree

.github/workflows/build.yml

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,22 +16,25 @@ jobs:
1616
runs-on: windows-latest
1717

1818
steps:
19-
- name: Checkout code
19+
- name: Checkout
2020
uses: actions/checkout@v4
21+
with:
22+
fetch-depth: 0 # Fetch all history for GitVersion to work properly
2123

2224
- name: Setup .NET
2325
uses: actions/setup-dotnet@v4
2426
with:
2527
dotnet-version: '8.0.x'
2628

2729
- name: Install GitVersion
28-
uses: gittools/actions/gitversion/setup@v0.11.0
30+
uses: gittools/actions/gitversion/setup@v4.2.0
2931
with:
30-
versionSpec: '5.x'
32+
versionSpec: '6.4.x'
33+
preferLatestVersion: true
3134

3235
- name: Run GitVersion
3336
id: gitversion
34-
uses: gittools/actions/gitversion/execute@v0.11.0
37+
uses: gittools/actions/gitversion/execute@v4.2.0
3538

3639
- name: Display GitVersion outputs
3740
run: |

GitVersion.yml

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,13 @@
11
next-version: 2.0.0
22
mode: ContinuousDeployment
3-
assembly-informational-format: '{MajorMinorPatch}'
3+
tag-prefix: '[vV]?'
4+
assembly-informational-format: '{Major}.{Minor}.{Patch}'
5+
major-version-bump-message: '\+semver:\s?(breaking|major)'
6+
minor-version-bump-message: '\+semver:\s?(feature|minor)'
7+
patch-version-bump-message: '\+semver:\s?(fix|patch)'
8+
no-bump-message: '\+semver:\s?(none|skip)'
9+
commit-message-incrementing: Enabled
10+
update-build-number: true
411
branches:
512
master:
613
regex: ^master$

0 commit comments

Comments
 (0)