Skip to content

Commit 21ef845

Browse files
authored
🔧Set assembly file version to match nuget version (v5) (#1581)
Fixes #1557 The assembly file version was incorrectly set to the same as `<AssemblyVersion>`, which is fixed to the major version for strong naming. ### Changes - Explicitly configure `<FileVersion>` to match the nuget package version
1 parent 5b0b4d0 commit 21ef845

File tree

4 files changed

+8
-5
lines changed

4 files changed

+8
-5
lines changed

UnitsNet.Benchmark/UnitsNet.Benchmark.csproj

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22
<PropertyGroup>
33
<OutputType>Exe</OutputType>
44
<TargetFrameworks>net9.0;net48</TargetFrameworks>
5-
<Version>4.0.0.0</Version>
6-
<AssemblyVersion>4.0.0.0</AssemblyVersion>
5+
<Version>5.0.0.0</Version>
6+
<AssemblyVersion>5.0.0.0</AssemblyVersion>
77
<AssemblyTitle>UnitsNet.Benchmark</AssemblyTitle>
88
<Product>UnitsNet.Benchmark</Product>
99
<RootNamespace>UnitsNet.Benchmark</RootNamespace>

UnitsNet.NumberExtensions/UnitsNet.NumberExtensions.csproj

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,8 @@
1818
</PropertyGroup>
1919

2020
<PropertyGroup>
21-
<AssemblyVersion>5.0.0.0</AssemblyVersion>
21+
<AssemblyVersion>5.0.0.0</AssemblyVersion> <!-- Fixed to major version, for strong naming -->
22+
<FileVersion>$(Version)</FileVersion> <!-- Will match NuGet version -->
2223
<LangVersion>latest</LangVersion>
2324
<Nullable>enable</Nullable>
2425
<RootNamespace>UnitsNet</RootNamespace>

UnitsNet.Serialization.JsonNet/UnitsNet.Serialization.JsonNet.csproj

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,8 @@
2020

2121
<!-- Assembly and msbuild properties -->
2222
<PropertyGroup>
23-
<AssemblyVersion>5.0.0.0</AssemblyVersion> <!-- Should reflect major part of Version -->
23+
<AssemblyVersion>5.0.0.0</AssemblyVersion> <!-- Fixed to major version, for strong naming -->
24+
<FileVersion>$(Version)</FileVersion> <!-- Will match NuGet version -->
2425
<LangVersion>latest</LangVersion>
2526
<Nullable>enable</Nullable>
2627
<RootNamespace>UnitsNet.Serialization.JsonNet</RootNamespace>

UnitsNet/UnitsNet.csproj

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,8 @@
2020

2121
<!-- Assembly and msbuild properties -->
2222
<PropertyGroup>
23-
<AssemblyVersion>5.0.0.0</AssemblyVersion> <!-- Should reflect major part of Version -->
23+
<AssemblyVersion>5.0.0.0</AssemblyVersion> <!-- Fixed to major version, for strong naming -->
24+
<FileVersion>$(Version)</FileVersion> <!-- Will match NuGet version -->
2425
<LangVersion>latest</LangVersion>
2526
<Nullable>enable</Nullable>
2627
<RootNamespace>UnitsNet</RootNamespace>

0 commit comments

Comments
 (0)