Questions tagged [gitversion]
GitVersion uses your Git history to infer your semantic version using a set of built in conventions. It currently works with GitHubFlow and GitFlow.
gitversion
224 questions
2
votes
1
answer
157
views
How do I increment SemVer per commit using gitversion?
When using gitversion (the latest, v6.*) in a github action, is the SemVer supposed to increase by 1 at the end each commit? I thought it was from what I was ...
1
vote
0
answers
395
views
GitVersion: No base versions determined on the current branch
I am unable to calculate versions with GitVersion. The repo I am testing on does not have any previous tags or releases. I am using the CLI version of the tool, not the actions (on github enterprise ...
1
vote
0
answers
39
views
GitVersion increment label
How can I increment label?
I.e X.X.X-labelname.Y (increment the y number) every time a change is made to main branch
My GitVersion.yaml
I currently have
...
0
votes
0
answers
35
views
Can I configure GitVersion to genereate version in format: <const>.Major.Minor? e.g. 25.Major.Minor
I am working on plugin development and my plugin has to run in the 2024 AND 2025 version of the Host application.
The source code is written so that at any time - any checkin / any git node - I can ...
0
votes
0
answers
197
views
How to override default GitVersion behavior to bump version using both tags and commit messages (GitFlow mode)
I'm using GitVersion with the default GitFlow workflow (workflow: GitFlow/v1), and I want to leverage both:
Use annotated Git tags (e.g. v1.2.0) to create stable releases
Use +semver: in commit ...
1
vote
0
answers
349
views
How to Configure GitVersion for Stable Main Versions and Pre-Release Feature Tags with Patch Increments?
I'm trying to set up GitVersion (dotnet-gitversion tool version 6.1) so that:
The main branch always produces stable versions without any pre-release tags.
All branches, including feature branches, ...
0
votes
1
answer
516
views
Azure DevOps release pipeline throws error on Gitversion updatebuildnumber
I am using Gitversion tasks in Azure Release pipeline to find the next tag sequence. I have added update-build-number=false in the execute gitversion task.
...
0
votes
1
answer
178
views
Azure DevOps Yaml pipeline - GitVersionfor additional repository
I have Azure DevOps Yaml pipeline with 2 repositories used:
Main repo: the one with .yml files (in my example branch used: ...
0
votes
1
answer
494
views
GitVersion doesn't use the "label" string when on master
I've recently upgraded to GitVersion 6.0.x (due to various other issues) and now I can't seem to get my master builds to get versioned correctly. I want the master builds to be named "-alpha"...
2
votes
1
answer
765
views
GitVersion doesn't cause error in Azure Devops Pipeline
I'm creating an Azure Devops pipeline to build a small library. As it's a tiny project, I don't use branches to develop functionalities. I work inside the master branch.
Here is the beginning of my <...
0
votes
1
answer
3k
views
Implementing GitVersion in Azure Pipelines for GitHub Flow
I am trying to us GitVersion in Azure Pipelines to help with auto-versioning our builds/commits. My flow is very similar to what is shown in this Feature Branch ...
1
vote
0
answers
200
views
Nuke Build with GitVersion
I've been using Nuke Build with GitVersion for a while now quite successfully.
However I've tried the upgrade to v6.0.0 of GitVersion in Nuke and it seems to cause me problems.
I'm using Nuke to ...
2
votes
1
answer
1k
views
Azure DevOps task fails to checkout disabling shallow
In my Azure DevOps pipeline I'm using GitVersion to determine a version number for my software system using semantic versioning. At this time, the GitVersion task fails because my repo is shallow. To ...
0
votes
2
answers
712
views
CVE-2024-32002 - ADO vulnerability?
My organisation have an instance of Azure DevOps Services. I have noticed recently that this vulnerability was opened on GIT:
https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2024-32002
I am ...
4
votes
1
answer
3k
views
GitVersion 6.0.0 'Property 'tag' not found error
I needed to upgrade to GitVersion 6.0.0-beta.6 for .NET 8 support, but this leads to following exception in my Gitlab CI Build Job: An error occurred:
Could not build the configuration instance ...
0
votes
0
answers
81
views
not bumping version correctly using gitversion
I am using gitversion in azure devops. But it is not calculating the version correctly. As I am implementing it in existing repo, which has a lot of history with something like release-03082024 in ...
1
vote
0
answers
342
views
Why is version patch not being incremented using Gitversion in Github Actions?
I am using GitVersion with Github Actions with main branch.
When a new tag is pushed to main branch, e.g. v2.0.0, I want to increase the patch:
...
1
vote
0
answers
173
views
First version after tag push has patch equal to 1 and not 0. Why?
I am using GitVersion with Github Actions with main branch.
When a new tag is pushed to main branch, e.g. v2.0.0, I want to increase the patch:
...
2
votes
1
answer
894
views
AzurePipeline GitVersion step not finding the config.yaml
I've run out of idea trying to get my azure pipeline to work.
I have 2 repositories, one for the pipelines templates and one for my project.
Idea is to have generic pipelines ready to use in my ...
0
votes
1
answer
158
views
Gitversion "could not load ssl libraries" error on TeamCity with normalization enabled
Currently, I am in the process of migrating the TeamCity Agent from AWS Linux2 to AWS Linux2023. I have a problem with the git-version application. I'm receiving an error:
...
1
vote
0
answers
314
views
How to update the version of a package in Deploy->Package Registry of gitlab
I have a static version in pyproject.toml, I want the version to be dynamic, everytime when I deploy the latest version I want to update the version of the package ...
0
votes
0
answers
1k
views
Correct way to use git version in a GitHub action .NET Core
I have an API in .NET Core
I'm new in Github actions and I am trying to set a github action that everytime we send a PR, it updates the API project version. I'm working with dependabot, so the idea is ...
0
votes
0
answers
2k
views
How to tell Gitversion to increment versions on every merge on dev?
We create our features on feature/* branches and we make Pull Requests on Azure DevOps to merge them on dev branch.
On the PR, ...
0
votes
1
answer
194
views
Gitversion issues with incrementing version
I have a circleci pipeline that process a net core project and generate a nuget package.
I followed the steps in this great tutorial https://renatogolia.com/2022/12/23/publish-nuget-package-with-...
1
vote
1
answer
339
views
How to interact with GitVersion init in Visual Studio Package Manager Console
When using GitVersion you interact by using gitversion init to access the executable available via NuGet.
However it looks like the package manager console does not ...
0
votes
1
answer
738
views
GitVersion to correctly update assembly version for master, dev, hotfix branches
I am using GitVersion in an Azure DevOps pipeline to automate deployments, however I'm struggling to get the automatic versioning to work as I want.
The branch structure is like this:
...
0
votes
0
answers
452
views
GitVersion Error: The process '/opt/hostedtoolcache/GitVersion.Tool/5.12.0/x64/dotnet-gitversion'
Im implementing CI/CD process with github actions into my flutter app, Im using gitversion to manage verions that is my actions file configuration
...
0
votes
0
answers
590
views
Azure Devops and release of multiple repositories
I have multiple repositories which contain microservices. What I want to do is that when I release a new version I want to deploy the whole system. Each repo generates a docker image and deployments ...
0
votes
0
answers
520
views
Proper maven projects versioning strategy
I have a development in course, based on many projects (each of which represents a microservice). All of them are using the Spring Boot Framework and must be compiled in Azure Devops in order to ...
2
votes
1
answer
10k
views
fetch-depth: 0 on github actions checkout is not fetching all tags and refs
I have a repo which has a TAG 1.0.0 on main and i am running a github workflow on branch "dev"
...
0
votes
1
answer
188
views
Versioning Approach In Custom Git Strategy
Overview:
Here is the git strategy I have:
main branch reflects production
developer creates branch from main with feature/jiraTiketNb and implements it there
developer can merge any time feature/...
0
votes
1
answer
998
views
When making NuGet packages from C# using GitVersion.MsBuild and dotnet pack, what determines whether the NuGet name gets a timestamp suffix or not?
I am generating NuGet packages from a C# project. My C# project references GitVersion.MsBuild version 5.12.0. When I build and then call dotnet pack, by default my NuGet gets a name like this:
...
0
votes
1
answer
744
views
How to access AssemblyInfo generated by GitVersion.MSBuild from aspx.net framework 4.8 project
I am working on a .net project and I am not able to understand how to access the assembly version from the AssemblyVersion.cs file that is being generated by the GitVersion.MSBuild task.
I would like ...
0
votes
1
answer
60
views
Build and Publish azure pipeine using gitversion - version collision
I have a problem, of course. I lost 4 days trying to make it work but without success.
What I want is, using gitversion task, to build and publish main and develop branches to artifact feed. For ...
2
votes
1
answer
908
views
Using C#, GitVersion.MsBuild and dotnet pack, how can I put a suffix in my NuGet name like "MyProject-1.0.0--staging.nupkg"?
I am generating a NuGet package from a C# project. I want to be able to set suffixes on my NuGet package names, such as MyProject-1.0.0--staging and MyProject-1.0.0--development.
Merely renaming the ....
2
votes
1
answer
2k
views
GitVersion not respecting tag-prefix
The Background:
I have a Git repository with random tags for various things however when our pipeline runs we execute GitVersion to calculate the version number for a nuget package in the solution. ...
0
votes
1
answer
247
views
Add a condition to run Gitversion when branch is main
We are using a Azure yaml pipeline and Gitversion, configured to version up based on PR templates.
...
2
votes
0
answers
1k
views
GitVersion incrementing Major and Minor versions but not Patch
We are trying to overhaul our GitVersion setup and for some reason the Patch version is not incrementing in our release branches, either automatically or explicitly with ...
1
vote
0
answers
183
views
java.lang.NumberFormatException: For input string - in github version and tag
I made a release in version v1.0.0-a1 on github and I launched the build on jenkins, until there all worked very well then I create a new tag v1.0.0-a2 on github and I relaunch a build. Since I have ...
1
vote
1
answer
617
views
Error "-outputfile" when building a project on gitlab
In my project, I use the GitVersion.MsBuild library to keep track of the application version on the wpf.
When building in gitlab there is an
...
1
vote
0
answers
561
views
GitVersion: always Patch incrementing, Minor is not getting incremented
I have a requirement for Automatic versioning based on branches.
I have set a tag on my master branch as 1.0.0
if changes from feature branch get merged to Master then Minor should get incremented as ...
2
votes
1
answer
797
views
How can I get the GitVersion version into my binary?
I am using GitVersion to version my C#.NET application. My application also has a -V option, to show the current version of the ...
1
vote
0
answers
136
views
can we change something in gitversion to always return a 2 digit major version?
We have the pipeline yml file autogenerate our software part number using the git version info. We are having a problem with the number of digits and I'm not sure how/of we can implement the logic in ...
0
votes
1
answer
344
views
TFS - GitVersion - A supported task execution handler was not found
I have on-prem TFS 2015, and want to run gitversion, so added step as below:
GitVersion.yml:
...
-1
votes
1
answer
468
views
Auto-update feature for wpf application
I am trying to do auto-update process. I having my updated version exe in my GitHub When I start the lower version exe from my local machine. It really want me ask me for update. That updated should ...
0
votes
1
answer
962
views
How to increment manually semVer GitTools in azure pipeline?
I use GitTools for auto increment semVer.
The current version: v1.1.1
calculate SemVer:
"MajorMinorPatch": "1.2.0"
when incrementing the patch:
<...
0
votes
1
answer
216
views
GitVersion: Copyright attribute missing when publishing a single file with *GenerateAssemblyInfo* set to *false*
I am using GitVersion in my WPF-project. When publishing my app I use profile setting Produce single file which I want to stick to. Publish only runs successfully if I set im my .csproj-file:
...
1
vote
1
answer
4k
views
How I can bump the version to 1.0.0 by GitVersion
I operate git-version with git-flow.
I want to bump version up to 1.0.0 when I merge develop to main.
Version as of develop is 0.1.0, and I did merge it to main with commit message contains bumping ...
3
votes
1
answer
3k
views
Gitversion fails to get the JSON data
I am working on a project based on this repo
(I would ask the question on it's issues, but it is quite stale...)
I am trying to do the task, to create the the pipeline, but it fails within this step:
<...
6
votes
2
answers
2k
views
Azure DevOps Yaml Pipline gitversion/execute failing ObjectHandle.op_Implicit(ObjectHandle handle) in /_/LibGit2Sharp/Core/Handles/Objects.cs:line 509
Getting error when run task gitversion/execute on azure devops yaml pipeline
...