Skip to content
This repository was archived by the owner on Feb 15, 2023. It is now read-only.

Update implicit metapackage version for 2.2 apps #348

Merged
merged 6 commits into from
Jun 1, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 21 additions & 9 deletions src/Web/Microsoft.NET.Sdk.Web.Targets/Sdk.DefaultItems.targets
Original file line number Diff line number Diff line change
Expand Up @@ -29,37 +29,49 @@ Copyright (c) .NET Foundation. All rights reserved.
automatically selects the version of .NET Core to target.

The framework version that is written to the runtimeconfig.json file is based on the actual resolved package version
of Microsoft.AspNetCore.App or Microsoft.AspNetCore.All. This is to allow floating the verion number (i.e. the user
of Microsoft.AspNetCore.App or Microsoft.AspNetCore.All. This is to allow floating the version number (i.e. the user
could set the version to "2.0-*".

-->
<Choose>
<When Condition="'$(TargetFrameworkIdentifier)' == '.NETCoreApp'" >

<PropertyGroup>
<!-- These properties will allow the latest patch versions to be set in the CLI (via BundledVersions.props) or overridden by tests -->
<DefaultPatchVersionForAspNetCoreAll2_1 Condition="'$(DefaultPatchVersionForAspNetCoreAll2_1)' == ''">2.1.1</DefaultPatchVersionForAspNetCoreAll2_1>
<DefaultPatchVersionForAspNetCoreApp2_1 Condition="'$(DefaultPatchVersionForAspNetCoreApp2_1)' == ''">2.1.1</DefaultPatchVersionForAspNetCoreApp2_1>
</PropertyGroup>

<!-- Default patch version of .All Framework -->
<PropertyGroup Condition="'$(DefaultAspNetCoreAllPatchVersion)' == ''">
<DefaultAspNetCoreAllPatchVersion Condition="'$(_TargetFrameworkVersionWithoutV)' == '2.1'">$(DefaultPatchVersionForAspNetCoreAll2_1)</DefaultAspNetCoreAllPatchVersion>
<DefaultAspNetCoreAllPatchVersion Condition="'$(_TargetFrameworkVersionWithoutV)' == '2.2'">$(DefaultPatchVersionForAspNetCoreAll2_2)</DefaultAspNetCoreAllPatchVersion>

<!-- If targeting the same pre-release that is bundled with the .NET Core SDK, use the bundled package version
provided by Microsoft.NETCoreSdk.BundledVersions.props -->
<DefaultAspNetCoreAllPatchVersion Condition="'$(_TargetFrameworkVersionWithoutV)' == '$(BundledAspNetCoreAllTargetFrameworkVersion)'">$(BundledAspNetCoreAllPackageVersion)</DefaultAspNetCoreAllPatchVersion>
<DefaultAspNetCoreAllPatchVersion Condition="'$(DefaultAspNetCoreAllPatchVersion)' == '' AND '$(_TargetFrameworkVersionWithoutV)' == '$(BundledAspNetCoreAllTargetFrameworkVersion)'">$(BundledAspNetCoreAllPackageVersion)</DefaultAspNetCoreAllPatchVersion>
<!-- If not covered by the previous cases use the target framework version for the default patch version -->
<DefaultAspNetCoreAllPatchVersion Condition="'$(DefaultAspNetCoreAllPatchVersion)' == ''">$(_TargetFrameworkVersionWithoutV)</DefaultAspNetCoreAllPatchVersion>
</PropertyGroup>

<!-- Default patch version of .App Framework -->
<PropertyGroup Condition="'$(DefaultAspNetCoreAppPatchVersion)' == ''">
<DefaultAspNetCoreAppPatchVersion Condition="'$(_TargetFrameworkVersionWithoutV)' == '2.1'">$(DefaultPatchVersionForAspNetCoreApp2_1)</DefaultAspNetCoreAppPatchVersion>
<DefaultAspNetCoreAppPatchVersion Condition="'$(_TargetFrameworkVersionWithoutV)' == '2.2'">$(DefaultPatchVersionForAspNetCoreApp2_2)</DefaultAspNetCoreAppPatchVersion>

<!-- If targeting the same pre-release that is bundled with the .NET Core SDK, use the bundled package version
provided by Microsoft.NETCoreSdk.BundledVersions.props -->
<DefaultAspNetCoreAppPatchVersion Condition="'$(_TargetFrameworkVersionWithoutV)' == '$(BundledAspNetCoreAppTargetFrameworkVersion)'">$(BundledAspNetCoreAppPackageVersion)</DefaultAspNetCoreAppPatchVersion>
<DefaultAspNetCoreAppPatchVersion Condition="'$(DefaultAspNetCoreAppPatchVersion)' == '' AND '$(_TargetFrameworkVersionWithoutV)' == '$(BundledAspNetCoreAppTargetFrameworkVersion)'">$(BundledAspNetCoreAppPackageVersion)</DefaultAspNetCoreAppPatchVersion>
<!-- If not covered by the previous cases use the target framework version for the default patch version -->
<DefaultAspNetCoreAppPatchVersion Condition="'$(DefaultAspNetCoreAppPatchVersion)' == ''">$(_TargetFrameworkVersionWithoutV)</DefaultAspNetCoreAppPatchVersion>
</PropertyGroup>

<!-- Latest patch version of .All Framework -->
<PropertyGroup Condition="'$(LatestAspNetCoreAllPatchVersion)' == ''">
<!-- Placeholder for setting latest patch version using the bundled version from CLI -->
<!-- <LatestAspNetCoreAllPatchVersion Condition="'$(_TargetFrameworkVersionWithoutV)' == '2.1'">$(LatestPatchVersionForAspNetCoreAll2_1)</LatestAspNetCoreAllPatchVersion> -->
<LatestAspNetCoreAllPatchVersion Condition="'$(_TargetFrameworkVersionWithoutV)' == '2.1'">$(LatestPatchVersionForAspNetCoreAll2_1)</LatestAspNetCoreAllPatchVersion>
<LatestAspNetCoreAllPatchVersion Condition="'$(_TargetFrameworkVersionWithoutV)' == '2.2'">$(LatestPatchVersionForAspNetCoreAll2_2)</LatestAspNetCoreAllPatchVersion>

<!-- If targeting the same pre-release that is bundled with the .NET Core SDK, use the bundled package version
<!-- If targeting the same release that is bundled with the .NET Core SDK, use the bundled package version
provided by Microsoft.NETCoreSdk.BundledVersions.props -->
<LatestAspNetCoreAllPatchVersion Condition="'$(_TargetFrameworkVersionWithoutV)' == '$(BundledAspNetCoreAllTargetFrameworkVersion)'">$(BundledAspNetCoreAllPackageVersion)</LatestAspNetCoreAllPatchVersion>
<!-- If not covered by the previous cases use the target framework version for the latest patch version -->
Expand All @@ -68,10 +80,10 @@ Copyright (c) .NET Foundation. All rights reserved.

<!-- Latest patch version of .App Framework -->
<PropertyGroup Condition="'$(LatestAspNetCoreAppPatchVersion)' == ''">
<!-- Placeholder for setting latest patch version using the bundled version from CLI -->
<!-- <LatestAspNetCoreAppPatchVersion Condition="'$(_TargetFrameworkVersionWithoutV)' == '2.1'">$(LatestPatchVersionForAspNetCoreApp2_1)</LatestAspNetCoreAppPatchVersion> -->
<LatestAspNetCoreAppPatchVersion Condition="'$(_TargetFrameworkVersionWithoutV)' == '2.1'">$(LatestPatchVersionForAspNetCoreApp2_1)</LatestAspNetCoreAppPatchVersion>
<LatestAspNetCoreAppPatchVersion Condition="'$(_TargetFrameworkVersionWithoutV)' == '2.2'">$(LatestPatchVersionForAspNetCoreApp2_2)</LatestAspNetCoreAppPatchVersion>

<!-- If targeting the same pre-release that is bundled with the .NET Core SDK, use the bundled package version
<!-- If targeting the same release that is bundled with the .NET Core SDK, use the bundled package version
provided by Microsoft.NETCoreSdk.BundledVersions.props -->
<LatestAspNetCoreAppPatchVersion Condition="'$(_TargetFrameworkVersionWithoutV)' == '$(BundledAspNetCoreAppTargetFrameworkVersion)'">$(BundledAspNetCoreAppPackageVersion)</LatestAspNetCoreAppPatchVersion>
<!-- If not covered by the previous cases use the target framework version for the latest patch version -->
Expand Down