Skip to content

Commit 44c0e66

Browse files
authored
Shorten package version properties (dotnet#27784)
* Shorten package version properties - `$(...PackageVersion)` -> `$(...Version)` - inspired by a similar dotnet/efcore change - aligns names with Arcade SDK, meaning our values apply consistently * Remove unused PublishSymbols.proj and related property - restore Arcade's control of `$(MicrosoftSymbolUploaderBuildTaskVersion>)` - would otherwise result in a version downgrade * Update `$(MicrosoftNetCompilersToolsetVersion)` to match Arcade's value - avoid using an older toolset - now successfully overriding Arcade value * Avoid an odd `CS8603` error - delete the unused `GetOptionalProperty(...)` method * Correct an unintentional change reading package metadata - `%(ReferencePathWithRefAssemblies.NuGetPackageVersion)` is the correct name
1 parent f83817e commit 44c0e66

File tree

68 files changed

+426
-503
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

68 files changed

+426
-503
lines changed

Diff for: Directory.Build.targets

+5-5
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,8 @@
3737
<PackageBrandingVersion>$(VersionPrefix)</PackageBrandingVersion>
3838
<PackageBrandingVersion Condition=" '$(VersionSuffix)' != '' ">$(PackageBrandingVersion) $(BrandingVersionSuffix.Trim())</PackageBrandingVersion>
3939

40-
<SiteExtensionPackageVersion>$(VersionPrefix)</SiteExtensionPackageVersion>
41-
<SiteExtensionPackageVersion Condition=" '$(VersionSuffix)' != '' ">$(VersionPrefix)-$(VersionSuffix.Replace('.','-'))</SiteExtensionPackageVersion>
40+
<SiteExtensionVersion>$(VersionPrefix)</SiteExtensionVersion>
41+
<SiteExtensionVersion Condition=" '$(VersionSuffix)' != '' ">$(VersionPrefix)-$(VersionSuffix.Replace('.','-'))</SiteExtensionVersion>
4242

4343
<PackageVersion Condition=" '$(PackageVersion)' == '' ">$(Version)</PackageVersion>
4444

@@ -49,7 +49,7 @@
4949
<TargetingPackVersion>$(SharedFxVersion)</TargetingPackVersion>
5050
<TargetingPackVersion Condition=" ! $(IsTargetingPackBuilding) ">$(TargetingPackVersionPrefix)</TargetingPackVersion>
5151

52-
<PackageVersion Condition=" '$(NoSemVer20)' == 'true' ">$(SiteExtensionPackageVersion)</PackageVersion>
52+
<PackageVersion Condition=" '$(NoSemVer20)' == 'true' ">$(SiteExtensionVersion)</PackageVersion>
5353
</PropertyGroup>
5454

5555
<PropertyGroup>
@@ -155,7 +155,7 @@
155155
<!-- Only update the default runtime version for preview builds. -->
156156
<DefaultRuntimeFrameworkVersion Condition="'%(TargetFramework)' == '$(KnownAppHostPackOrFrameworkReferenceTfm)' and '$(IsServicingBuild)' != 'true'">$(MicrosoftNETCoreAppRuntimeVersion)</DefaultRuntimeFrameworkVersion>
157157
<!-- Only update the targeting pack version for preview builds. -->
158-
<TargetingPackVersion Condition="'%(TargetFramework)' == '$(KnownAppHostPackOrFrameworkReferenceTfm)' and '$(IsServicingBuild)' != 'true'">$(MicrosoftNETCoreAppRefPackageVersion)</TargetingPackVersion>
158+
<TargetingPackVersion Condition="'%(TargetFramework)' == '$(KnownAppHostPackOrFrameworkReferenceTfm)' and '$(IsServicingBuild)' != 'true'">$(MicrosoftNETCoreAppRefVersion)</TargetingPackVersion>
159159
</KnownFrameworkReference>
160160

161161
<KnownFrameworkReference Condition="'$(UseAspNetCoreSharedRuntime)' != 'true'" Remove="Microsoft.AspNetCore.App" />
@@ -169,7 +169,7 @@
169169

170170
<!-- Track compiler separately from Arcade.-->
171171
<PackageReference Include="Microsoft.Net.Compilers.Toolset"
172-
Version="$(MicrosoftNetCompilersToolsetPackageVersion)"
172+
Version="$(MicrosoftNetCompilersToolsetVersion)"
173173
PrivateAssets="all"
174174
IsImplicitlyDefined="true" />
175175
</ItemGroup>

Diff for: docs/ReferenceResolution.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ Steps for adding a new package dependency to an existing project. Let's say I'm
5454
1. Add the package to the .csproj file using `<Reference Include="System.Banana" />`
5555
2. Add an entry to [eng/Dependencies.props](/eng/Dependencies.props) e.g. `<LatestPackageReference Include="System.Banana" />`
5656
3. If this package comes from another dotnet team and should be updated automatically by our bot&hellip;
57-
1. Add an entry to [eng/Versions.props](/eng/Versions.props) like this `<SystemBananaPackageVersion>0.0.1-beta-1</SystemBananaPackageVersion>`.
57+
1. Add an entry to [eng/Versions.props](/eng/Versions.props) like this `<SystemBananaVersion>0.0.1-beta-1</SystemBananaVersion>`.
5858
2. Add an entry to [eng/Version.Details.xml](/eng/Version.Details.xml) like this:
5959

6060
```xml

Diff for: eng/Dependencies.props

+1-1
Original file line numberDiff line numberDiff line change
@@ -196,7 +196,7 @@ and are generated based on the last package release.
196196

197197
<!-- Get versions. -->
198198
<LatestPackageReference Update="@(LatestPackageReference)">
199-
<Version>$(%(VersionName)PackageVersion)</Version>
199+
<Version>$(%(VersionName)Version)</Version>
200200
</LatestPackageReference>
201201

202202
<!--

Diff for: eng/PublishSymbols.proj

-64
This file was deleted.

0 commit comments

Comments
 (0)