Skip to content
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

EnC: Add asterisk based assembly version docs #73364

Merged
merged 2 commits into from
May 8, 2024
Merged

Conversation

tmat
Copy link
Member

@tmat tmat commented May 7, 2024

Document workaround for projects containing * in assembly version.

@dotnet-issue-labeler dotnet-issue-labeler bot added Area-Infrastructure untriaged Issues and PRs which have not yet been triaged by a lead labels May 7, 2024
@tmat
Copy link
Member Author

tmat commented May 7, 2024

@AArnott please review if Nerdbank.GitVersioning info is accurate.

@tmat
Copy link
Member Author

tmat commented May 7, 2024

@davidwengier PTAL

It is thus highly recommended to use alternative versioning methods, such as [Nerdbank.GitVersioning](https://github.com/dotnet/Nerdbank.GitVersioning), that derive the assembly version
from the HEAD commit SHA (for git repositories).

> To enable generating commit SHA based assembly versions using `Nerdbank.GitVersioning` package, specify `{ "assemblyVersion" : {"precision": "revision"} }` setting in `version.json`.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is accurate, although I wonder if it's common for users to use wildcards with AssemblyVersion as opposed to AssemblyFileVersion. Having AssemblyVersion change with every single has at least historically been problematic (for strong named assemblies) so I would expect wildcards to be used for the file version instead. And in that case, this JSON isn't necessary, because AssemblyFileVersion by default includes a commit SHA component.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We have seen customers using wildcard in assembly version, which is causing Hot Reload issues.

@tmat tmat merged commit a1e7312 into dotnet:main May 8, 2024
5 checks passed
@tmat tmat deleted the VersionAsterisk branch May 8, 2024 16:02
@dotnet-policy-service dotnet-policy-service bot added this to the Next milestone May 8, 2024
@Cosifne Cosifne modified the milestones: Next, 17.11 P2 May 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area-Infrastructure untriaged Issues and PRs which have not yet been triaged by a lead
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants