Skip to content

Commit

Permalink
Added docs re automatic generation of AssemblyInformationalVersionAtt…
Browse files Browse the repository at this point in the history
…ribute (#11012)
  • Loading branch information
jamescrosswell authored Sep 11, 2024
1 parent b7222af commit a6564b7
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions platform-includes/set-release/dotnet.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,7 @@ The SDK attempts to locate the release to attach to events sent to Sentry.
The SDK will first check if there's a version set on the environment via `SENTRY_RELEASE` and use it as-is.

If no version is found, the SDK will look at the [entry assembly's](<https://msdn.microsoft.com/en-us/library/system.reflection.assembly.getentryassembly(v=vs.110).aspx>) `AssemblyInformationalVersionAttribute`, which accepts a string value and is often used to set a GIT commit hash. If that returns null, then the SDK will look at the default `AssemblyVersionAttribute`, which accepts the numeric version number. The resulting release will be in the format `<assembly-name>@<version-number>`.

<Note>
An `AssemblyInformationalVersionAttribute` is included automatically in SDK-style projects with a default value of `"1.0.0.0"`. You can set the `Version` property in your project file to override this value or [disable it entirely](https://learn.microsoft.com/en-us/dotnet/standard/assembly/set-attributes-project-file#use-package-properties-as-assembly-attributes) by setting the `GenerateAssemblyInformationalVersionAttribute` property to `false`.
</Note>

0 comments on commit a6564b7

Please sign in to comment.