Support using Internal.AspNetCore.Sdk as an MSBuild SDK (#1452)

* Add Microsoft.AspNetCore.BuildTools.ApiCheck as an external dependency
* Move the global.json files temporarily to avoid loading the wrong version of Internal.AspNetCore.Sdk
This commit is contained in:
Nate McMaster 2018-10-04 11:07:06 -07:00 committed by GitHub
parent 5d261e46ce
commit b0b65a530a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 13 additions and 4 deletions

View File

@ -14,6 +14,7 @@
<MicrosoftNETCoreApp22PackageVersion Condition="'$(MicrosoftNETCoreAppPackageVersion)' != ''">$(MicrosoftNETCoreAppPackageVersion)</MicrosoftNETCoreApp22PackageVersion>
<!-- Determined by build tools -->
<MicrosoftAspNetCoreBuildToolsApiCheckPackageVersion>$(KoreBuildVersion)</MicrosoftAspNetCoreBuildToolsApiCheckPackageVersion>
<InternalAspNetCoreSdkPackageVersion>$(KoreBuildVersion)</InternalAspNetCoreSdkPackageVersion>
<InternalAspNetCoreSiteExtensionSdkPackageVersion>$(KoreBuildVersion)</InternalAspNetCoreSiteExtensionSdkPackageVersion>
</PropertyGroup>

View File

@ -19,6 +19,7 @@
<ExternalDependency Include="FSharp.Core" Version="$(FSharpCorePackageVersion)" />
<ExternalDependency Include="Google.Protobuf" Version="$(GoogleProtobufPackageVersion)" />
<ExternalDependency Include="Internal.AspNetCore.Sdk" Version="$(InternalAspNetCoreSdkPackageVersion)" />
<ExternalDependency Include="Microsoft.AspNetCore.BuildTools.ApiCheck" Version="$(MicrosoftAspNetCoreBuildToolsApiCheckPackageVersion)" />
<ExternalDependency Include="Internal.AspNetCore.SiteExtension.Sdk" Version="$(InternalAspNetCoreSiteExtensionSdkPackageVersion)" />
<ExternalDependency Include="Libuv" Version="$(LibuvPackageVersion)" />
<ExternalDependency Include="Microsoft.ApplicationInsights.AspNetCore" Version="$(MicrosoftApplicationInsightsAspNetCorePackageVersion)" />

View File

@ -79,6 +79,8 @@
<PackageArtifact Remove="@(PackageArtifact)" />
</ItemGroup>
<Move SourceFiles="%(SubmoduleGlobalJsonFiles.BackupPath)" DestinationFiles="%(SubmoduleGlobalJsonFiles.Identity)" Condition="Exists(%(SubmoduleGlobalJsonFiles.BackupPath))" />
<!-- Join required because shipping category is stored in universe (PackageArtifact), but information about package ID and version comes from repos (ArtifactInfo). -->
<RepoTasks.JoinItems
Left="@(_Temp)"
@ -208,7 +210,12 @@
<ItemGroup>
<Repository Update="%(Identity)" RootPath="$(SubmoduleRoot)%(Identity)\" />
<ShippedRepository Update="%(Identity)" RootPath="$(SubmoduleRoot)%(Identity)\" Condition="'%(Identity)' != ''" />
<SubmoduleGlobalJsonFiles Include="%(Repository.RootPath)global.json" BackupPath="$(IntermediateDir)%(Repository.Identity)-global.json" Condition="'%(Repository.Identity)' != ''"/>
<SubmoduleGlobalJsonFiles Include="%(ShippedRepository.RootPath)global.json" BackupPath="$(IntermediateDir)%(ShippedRepository.Identity)-global.json" Condition="'%(ShippedRepository.Identity)' != ''"/>
</ItemGroup>
<Move SourceFiles="%(SubmoduleGlobalJsonFiles.Identity)" DestinationFiles="%(SubmoduleGlobalJsonFiles.BackupPath)" Condition="Exists(%(SubmoduleGlobalJsonFiles.Identity))" />
</Target>
<Target Name="BuildRepositories"

View File

@ -3,6 +3,6 @@
"version": "2.2.100-preview2-009404"
},
"msbuild-sdks": {
"Internal.AspNetCore.Sdk": "2.2.0-preview2-20181003.2"
"Internal.AspNetCore.Sdk": "2.2.0-preview2-20181004.1"
}
}

View File

@ -1,2 +1,2 @@
version:2.2.0-preview2-20181003.2
commithash:41935e62d7853060283c801f49992e2c73a95927
version:2.2.0-preview2-20181004.1
commithash:20538607213e0d70ee0b3ae39c35e6d55cec8eda

@ -1 +1 @@
Subproject commit 5103fe7aee4b7d105fd88e7917c74804268aa676
Subproject commit ba6e9f51fc7b0faf97b4b2d96f4c07dd365b229f