How to use GitVersion /UpdateAssemblyInfo for changes that haven't been committed yet?

170 Views Asked by At

perhaps there's something that I don't understand when it comes to working with GitVersion.

Suppose I am on my main branch, and the latest commit has been tagged, with, say, 1.1.2. Now that my build works and that I am ready to release 1.1.3, I would like to update my AssemblyInfo file to match the next release.

However, when I build with GitVersion.exe /UpdateAssemblyInfo, it returns the current tag. How then, can I get my Assembly tagged with the right info? Given that I cannot tag something that I have not committed, I need to commit first, then rerun GitVersion.exe /UpdateAssemblyInfo.

My current workaround consists in committing twice then squashing the two commits, but there must be a better way to do this.

Thanks!

0

There are 0 best solutions below