Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

--version-suffix not changing Assembly version neither assembly file version

See original GitHub issue

Steps to reproduce

dotnet build --version-suffix [anything]

Expected behavior

Assembly version and Assembly file version are set to version-[anything]

Actual behavior

Assembly version and assembly file version are: version.0

to clarify, using dotnet build --version-suffix 9 will not change the assembly version nor the assembly file version, if put it manually with a dot "version": "" in the project json it works.

--version-suffix never changes assembly version or assembly file version, being numeric or not.

Environment data

dotnet --info output:

.NET Command Line Tools (1.0.0-preview1-002702)

Product Information: Version: 1.0.0-preview1-002702 Commit Sha: 6cde21225e

Runtime Environment: OS Name: Windows OS Version: 10.0.10586 OS Platform: Windows RID: win10-x64

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:7 (2 by maintainers)

github_iconTop GitHub Comments

TheRealPiotrPcommented, Jun 10, 2016

File and assembly version numbers only support four-part numeric version numbers. Semantic versions are not applicable and therefore ignored.

ChrisSimmonscommented, Nov 20, 2016

@ctrl-brk - I use this to get the product version (I don’t know if this is platform-agnostic, though):

string productVersion = 
Read more comments on GitHub >

github_iconTop Results From Across the Web

Version vs VersionSuffix vs PackageVersion: What do they ...
If assemblies are not strong-named signed, only file names are used for loading. You can read more about assembly versioning in the docs....
Read more >
AssemblyVersion using * fails with error "wildcards, which ...
"Deterministic" means something like - the compiler will use the same versions of the files if no changes have happened resulting in faster ......
Read more >
Setting assembly and nuget package metadata in .NET Core
If the Version property is hardcoded in the project's file, then passing VersionPrefix and VersionSuffix from the outside has no effect. The ...
Read more >
Assemblies versions are no longer being updated properly
I've been using my build profile for a while and it's been working great. One of the steps includes updating my ASP.NET Core's...
Read more >
Collected Notes on Modern .NET (6.0) Versioning
An overview of all aspects pertaining to .NET assembly and package versioning, as well as how to handle the automation of said versioning....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Post

No results found

github_iconTop Related Hashnode Post

No results found