Merge pull request #7848 from johnbeisner/PublishToTransportFeed
Enabling the publish of CLI NuPkg to the unified Transport feed.
This commit is contained in:
commit
7fe5bda018
6 changed files with 44 additions and 3 deletions
|
@ -8,7 +8,14 @@
|
|||
<ArtifactCloudDropAccountName Condition="'$(ArtifactCloudDropAccountName)' == ''">dotnetcli</ArtifactCloudDropAccountName>
|
||||
<DotnetBlobRootUrl>https://$(ArtifactCloudDropAccountName).blob.core.windows.net/$(ArtifactContainerName)</DotnetBlobRootUrl>
|
||||
<ChecksumContainerName>$(CHECKSUM_STORAGE_CONTAINER)</ChecksumContainerName>
|
||||
<ChecksumContainerName Condition="'$(ChecksumContainerName)' == ''">dotnet</ChecksumContainerName>
|
||||
<ChecksumCloudDropAccessToken>$(CHECKSUM_STORAGE_KEY)</ChecksumCloudDropAccessToken>
|
||||
<ChecksumCloudDropAccountName>$(CHECKSUM_STORAGE_ACCOUNT)</ChecksumCloudDropAccountName>
|
||||
<ChecksumCloudDropAccountName Condition="'$(ChecksumCloudDropAccountName)' == ''">dotnetclichecksums</ChecksumCloudDropAccountName>
|
||||
<TransportFeedContainerName>$(TRANSPORTFEED_STORAGE_CONTAINER)</TransportFeedContainerName>
|
||||
<TransportFeedContainerName Condition="'$(TransportFeedContainerName)' == ''">dotnet-core</TransportFeedContainerName>
|
||||
<TransportFeedCloudDropAccessToken>$(TRANSPORTFEED_STORAGE_KEY)</TransportFeedCloudDropAccessToken>
|
||||
<TransportFeedCloudDropAccountName>$(TRANSPORTFEED_STORAGE_ACCOUNT)</TransportFeedCloudDropAccountName>
|
||||
<TransportFeedCloudDropAccountName Condition="'$(TransportFeedCloudDropAccountName)' == ''">dotnetfeed</TransportFeedCloudDropAccountName>
|
||||
</PropertyGroup>
|
||||
</Project>
|
||||
|
|
|
@ -24,6 +24,7 @@
|
|||
<UsingTask TaskName="GenerateNuGetPackagesArchiveVersion" AssemblyFile="$(CLIBuildDll)" />
|
||||
<UsingTask TaskName="GetCurrentRuntimeInformation" AssemblyFile="$(CLIBuildDll)" />
|
||||
<UsingTask TaskName="MakeRelative" AssemblyFile="$(CLIBuildDll)" />
|
||||
<UsingTask TaskName="PushToBlobFeed" AssemblyFile="$(BuildTasksFeedDll)" />
|
||||
<UsingTask TaskName="RemoveAssetFromDepsPackages" AssemblyFile="$(CLIBuildDll)" />
|
||||
<UsingTask TaskName="ReplaceFileContents" AssemblyFile="$(CLIBuildDll)" />
|
||||
<UsingTask TaskName="SetBlobPropertiesBasedOnFileType" AssemblyFile="$(CLIBuildDll)" />
|
||||
|
|
|
@ -3,6 +3,7 @@
|
|||
<Import Project="$(MSBuildThisFileDirectory)/publish/FinishBuild.targets" />
|
||||
<Import Project="$(MSBuildThisFileDirectory)/publish/PublishContent.targets" />
|
||||
<Import Project="$(MSBuildThisFileDirectory)/publish/PublishDebian.targets" />
|
||||
<Import Project="$(MSBuildThisFileDirectory)/publish/PublishNupkgToTransportFeed.targets" />
|
||||
<Import Project="$(MSBuildThisFileDirectory)/publish/Badge.targets" />
|
||||
<Import Project="$(MSBuildThisFileDirectory)/publish/Checksum.targets" />
|
||||
<Import Project="$(MSBuildThisFileDirectory)/publish/RuntimeCoherence.targets" />
|
||||
|
@ -24,6 +25,7 @@
|
|||
GenerateChecksums;
|
||||
UploadArtifactsToAzure;
|
||||
UploadChecksumsToAzure;
|
||||
PublishNupkgToTransportFeed;
|
||||
PublishDebFilesToDebianRepo;
|
||||
PublishCliVersionBadge" />
|
||||
|
||||
|
@ -33,11 +35,13 @@
|
|||
Condition=" '$(IslinuxPortable)' != 'true' "/>
|
||||
<ForPublishing Include="%(GenerateArchivesInputsOutputs.Outputs)"
|
||||
Condition=" '$(IsLinuxDistroSpecific)' != 'true' "/>
|
||||
<ForPublishing Include="$(PackagesDirectory)/Microsoft*.nupkg"
|
||||
<ForPublishing Include="$(PackagesDirectory)/Microsoft.DotNet.Cli.Utils.*.nupkg"
|
||||
Condition=" '$(PUBLISH_NUPKG_TO_AZURE_BLOB)' != '' AND '$(OS)' == 'Windows_NT' And '$(Architecture)' == 'x64' "/>
|
||||
<ForPublishing Include="$(PackagesDirectory)/VS.Redist.Common.Net.Core.SDK.$(Architecture)*.nupkg"
|
||||
<ForPublishing Include="$(PackagesDirectory)/Microsoft.DotNet.MSBuildSdkResolver.*.nupkg"
|
||||
Condition=" '$(PUBLISH_NUPKG_TO_AZURE_BLOB)' != '' AND '$(OS)' == 'Windows_NT' And '$(Architecture)' == 'x64' "/>
|
||||
<ForPublishing Include="$(PackagesDirectory)/VS.Redist.Common.Net.Core.SDK.$(Architecture).*.nupkg"
|
||||
Condition=" '$(PUBLISH_NUPKG_TO_AZURE_BLOB)' != '' AND '$(OS)' == 'Windows_NT' "/>
|
||||
<ForPublishing Include="$(PackagesDirectory)/VS.Redist.Common.Net.Core.SDK.MSBuildExtensions*.nupkg"
|
||||
<ForPublishing Include="$(PackagesDirectory)/VS.Redist.Common.Net.Core.SDK.MSBuildExtensions.*.nupkg"
|
||||
Condition=" '$(PUBLISH_NUPKG_TO_AZURE_BLOB)' != '' AND '$(OS)' == 'Windows_NT' And '$(Architecture)' == 'x64' "/>
|
||||
</ItemGroup>
|
||||
|
||||
|
|
27
build/publish/PublishNupkgToTransportFeed.targets
Normal file
27
build/publish/PublishNupkgToTransportFeed.targets
Normal file
|
@ -0,0 +1,27 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup>
|
||||
<ItemsToPush Include="$(PackagesDirectory)/Microsoft.DotNet.Cli.Utils.*.nupkg" />
|
||||
</ItemGroup>
|
||||
|
||||
<PropertyGroup>
|
||||
<RelativePath>packages</RelativePath>
|
||||
</PropertyGroup>
|
||||
|
||||
<Target Name="PublishNupkgToTransportFeed" Condition=" '$(PUBLISH_NUPKG_TO_TRANSPORT_FEED)' == 'true' AND '$(OS)' == 'Windows_NT' And '$(Architecture)' == 'x64' " >
|
||||
<Error Condition="'$(TransportFeedContainerName)' == ''" Text="Missing property TransportFeedContainerName." />
|
||||
<Error Condition="'$(TransportFeedCloudDropAccountName)' == ''" Text="Missing property TransportFeedCloudDropAccountName." />
|
||||
<Error Condition="'$(TransportFeedCloudDropAccessToken)' == ''" Text="Missing property TransportFeedCloudDropAccessToken." />
|
||||
|
||||
<Message Text="Publish to $(TransportFeedContainerName) started" />
|
||||
<PushToBlobFeed AccountKey="$(TransportFeedCloudDropAccessToken)"
|
||||
AccountName="$(TransportFeedCloudDropAccountName)"
|
||||
ContainerName="$(TransportFeedContainerName)"
|
||||
IndexDirectory="$(IndexDirectory)"
|
||||
ItemsToPush="@(ItemsToPush)"
|
||||
Overwrite="false"
|
||||
PublishFlatContainer="false"
|
||||
RelativePath="$(RelativePath)" />
|
||||
|
||||
</Target>
|
||||
</Project>
|
|
@ -29,5 +29,6 @@
|
|||
<PackageReference Include="Microsoft.Build.Framework" Version="$(CLI_MSBuild_Version)" />
|
||||
<PackageReference Include="Microsoft.DotNet.PlatformAbstractions" Version="$(PlatformAbstractionsVersion)" />
|
||||
<PackageReference Include="Microsoft.DotNet.VersionTools" Version="$(VersionToolsVersion)" />
|
||||
<PackageReference Include="Microsoft.DotNet.Build.Tasks.Feed" Version="1.0.0-prerelease-01929-02" />
|
||||
</ItemGroup>
|
||||
</Project>
|
||||
|
|
|
@ -7,6 +7,7 @@
|
|||
<NuGetPackagesDir Condition=" '$(NuGetPackagesDir)' == '' ">$(RepoRoot)/.nuget/packages</NuGetPackagesDir>
|
||||
|
||||
<CLIBuildDll>$(RepoRoot)/build_projects/dotnet-cli-build/bin/dotnet-cli-build.dll</CLIBuildDll>
|
||||
<BuildTasksFeedDll>$(RepoRoot)/build_projects/dotnet-cli-build/bin/Microsoft.DotNet.Build.Tasks.Feed.dll</BuildTasksFeedDll>
|
||||
|
||||
<DisableImplicitFrameworkReferences>true</DisableImplicitFrameworkReferences>
|
||||
<DisableImplicitPackageTargetFallback>true</DisableImplicitPackageTargetFallback>
|
||||
|
|
Loading…
Reference in a new issue