Skip to content

[ISSUE]: semver not being read with 6.xx.xx when GenerateNuGetPackageOnBuild = True on csproj #4460

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
2 tasks done
berndesj opened this issue Mar 18, 2025 · 4 comments
Open
2 tasks done

Comments

@berndesj
Copy link

Prerequisites

  • I have written a descriptive issue title
  • I have searched issues to ensure it has not already been reported

GitVersion package

GitVersion.MsBuild

GitVersion version

6.0.0 and sub

Operating system

Windows

What are you seeing?

in my csproj i use Gitversion.MSBULD 5.12.0 and when i build localy or on pipeline the semver calculated is show on my nupkg when the GenerateNuGetPackageOnBuild is TRUE.

when i take a newer version 6.xx.xx it is not read and by default of VS i get 1.0.0 because i don't set Version in the csproj .

Image

What is expected?

i was just expecting to upgrade to 6 and above and it would have kept the version of semversion ....

Steps to Reproduce

take a csproj with gitversion.msbuild with 5.12 ....
then switch to 6.xx and you will see .

don,t forget to set GenerateNuGetPackageOnBuild = true

Image

RepositoryFixture Test

No response

Output log or link to your CI build (if appropriate).

@HHobeck
Copy link
Contributor

HHobeck commented Mar 19, 2025

Hi @berndesj.

Sorry if I'm so direct. It is not very constructive to create a ticket and say it was working in version 5.x and now it is not working. Also you have not provided any steps to reproduce (sample project). Please keep in mind this is an open source project without any sponsors and just voluntary contributors.

Anyway, if I'm not mistaken GitVersion.MsBuild just creates an AssemblyInfo.cs like:

[assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")]
[assembly: AssemblyInformationalVersion("1.1.0+Branch.main.Sha.722aad3217bd49a6576b6f82f60884e612f9ba58")]

Why do you think it is a bug in gitversion? Please analyze your problem by yourself and give detail information about what is exactly going wrong. What has changed and why (maybe it was intended)? And if you found a bug then please create a Pull-Request.

Thank you for your help!

@berndesj
Copy link
Author

hello , yes it is very direct . its my first time that i try to participate in any open source community , i have no experience in the way , fashion or else to deal with helping , working etc.

So pardon me my inexperience and i will stay quiet 🤫 and a side while i learn and guide myself alone to help this community .

Best regards

@arturcic
Copy link
Member

@berndesj thank you for your interest, community help is always welcome

@berndesj
Copy link
Author

hello artucic , you are welcome and i want to help .

i will try all those suggestion from my welcoming body Copilot and share it with you if it helps.

https://chatgpt.com/share/67dab76e-68d8-8011-8b71-5aee1b33806d

👋

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants