Merge upstream changes
This commit is contained in:
commit
9b331673fe
67 changed files with 877 additions and 316 deletions
|
@ -227,6 +227,8 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "tool_fsc", "src\tool_fsharp
|
||||||
EndProject
|
EndProject
|
||||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.DotNet.MSBuildSdkResolver", "src\Microsoft.DotNet.MSBuildSdkResolver\Microsoft.DotNet.MSBuildSdkResolver.csproj", "{FCDFAF40-CC16-4D49-96C0-E49F195E7142}"
|
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.DotNet.MSBuildSdkResolver", "src\Microsoft.DotNet.MSBuildSdkResolver\Microsoft.DotNet.MSBuildSdkResolver.csproj", "{FCDFAF40-CC16-4D49-96C0-E49F195E7142}"
|
||||||
EndProject
|
EndProject
|
||||||
|
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "dotnet-cli-build.Tests", "build_projects\dotnet-cli-build.Tests\dotnet-cli-build.Tests.csproj", "{84BB2DD5-B2D8-4C85-AAF9-29D2A74FBF94}"
|
||||||
|
EndProject
|
||||||
Global
|
Global
|
||||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||||
Debug|Any CPU = Debug|Any CPU
|
Debug|Any CPU = Debug|Any CPU
|
||||||
|
@ -1563,6 +1565,30 @@ Global
|
||||||
{FCDFAF40-CC16-4D49-96C0-E49F195E7142}.RelWithDebInfo|x64.Build.0 = Release|Any CPU
|
{FCDFAF40-CC16-4D49-96C0-E49F195E7142}.RelWithDebInfo|x64.Build.0 = Release|Any CPU
|
||||||
{FCDFAF40-CC16-4D49-96C0-E49F195E7142}.RelWithDebInfo|x86.ActiveCfg = Release|Any CPU
|
{FCDFAF40-CC16-4D49-96C0-E49F195E7142}.RelWithDebInfo|x86.ActiveCfg = Release|Any CPU
|
||||||
{FCDFAF40-CC16-4D49-96C0-E49F195E7142}.RelWithDebInfo|x86.Build.0 = Release|Any CPU
|
{FCDFAF40-CC16-4D49-96C0-E49F195E7142}.RelWithDebInfo|x86.Build.0 = Release|Any CPU
|
||||||
|
{84BB2DD5-B2D8-4C85-AAF9-29D2A74FBF94}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||||
|
{84BB2DD5-B2D8-4C85-AAF9-29D2A74FBF94}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||||
|
{84BB2DD5-B2D8-4C85-AAF9-29D2A74FBF94}.Debug|x64.ActiveCfg = Debug|Any CPU
|
||||||
|
{84BB2DD5-B2D8-4C85-AAF9-29D2A74FBF94}.Debug|x64.Build.0 = Debug|Any CPU
|
||||||
|
{84BB2DD5-B2D8-4C85-AAF9-29D2A74FBF94}.Debug|x86.ActiveCfg = Debug|Any CPU
|
||||||
|
{84BB2DD5-B2D8-4C85-AAF9-29D2A74FBF94}.Debug|x86.Build.0 = Debug|Any CPU
|
||||||
|
{84BB2DD5-B2D8-4C85-AAF9-29D2A74FBF94}.MinSizeRel|Any CPU.ActiveCfg = Debug|Any CPU
|
||||||
|
{84BB2DD5-B2D8-4C85-AAF9-29D2A74FBF94}.MinSizeRel|Any CPU.Build.0 = Debug|Any CPU
|
||||||
|
{84BB2DD5-B2D8-4C85-AAF9-29D2A74FBF94}.MinSizeRel|x64.ActiveCfg = Debug|Any CPU
|
||||||
|
{84BB2DD5-B2D8-4C85-AAF9-29D2A74FBF94}.MinSizeRel|x64.Build.0 = Debug|Any CPU
|
||||||
|
{84BB2DD5-B2D8-4C85-AAF9-29D2A74FBF94}.MinSizeRel|x86.ActiveCfg = Debug|Any CPU
|
||||||
|
{84BB2DD5-B2D8-4C85-AAF9-29D2A74FBF94}.MinSizeRel|x86.Build.0 = Debug|Any CPU
|
||||||
|
{84BB2DD5-B2D8-4C85-AAF9-29D2A74FBF94}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||||
|
{84BB2DD5-B2D8-4C85-AAF9-29D2A74FBF94}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||||
|
{84BB2DD5-B2D8-4C85-AAF9-29D2A74FBF94}.Release|x64.ActiveCfg = Release|Any CPU
|
||||||
|
{84BB2DD5-B2D8-4C85-AAF9-29D2A74FBF94}.Release|x64.Build.0 = Release|Any CPU
|
||||||
|
{84BB2DD5-B2D8-4C85-AAF9-29D2A74FBF94}.Release|x86.ActiveCfg = Release|Any CPU
|
||||||
|
{84BB2DD5-B2D8-4C85-AAF9-29D2A74FBF94}.Release|x86.Build.0 = Release|Any CPU
|
||||||
|
{84BB2DD5-B2D8-4C85-AAF9-29D2A74FBF94}.RelWithDebInfo|Any CPU.ActiveCfg = Release|Any CPU
|
||||||
|
{84BB2DD5-B2D8-4C85-AAF9-29D2A74FBF94}.RelWithDebInfo|Any CPU.Build.0 = Release|Any CPU
|
||||||
|
{84BB2DD5-B2D8-4C85-AAF9-29D2A74FBF94}.RelWithDebInfo|x64.ActiveCfg = Release|Any CPU
|
||||||
|
{84BB2DD5-B2D8-4C85-AAF9-29D2A74FBF94}.RelWithDebInfo|x64.Build.0 = Release|Any CPU
|
||||||
|
{84BB2DD5-B2D8-4C85-AAF9-29D2A74FBF94}.RelWithDebInfo|x86.ActiveCfg = Release|Any CPU
|
||||||
|
{84BB2DD5-B2D8-4C85-AAF9-29D2A74FBF94}.RelWithDebInfo|x86.Build.0 = Release|Any CPU
|
||||||
EndGlobalSection
|
EndGlobalSection
|
||||||
GlobalSection(SolutionProperties) = preSolution
|
GlobalSection(SolutionProperties) = preSolution
|
||||||
HideSolutionNode = FALSE
|
HideSolutionNode = FALSE
|
||||||
|
@ -1633,6 +1659,7 @@ Global
|
||||||
{08A40B6A-F695-4EA9-AC8D-CF88FADEA796} = {17735A9D-BFD9-4585-A7CB-3208CA6EA8A7}
|
{08A40B6A-F695-4EA9-AC8D-CF88FADEA796} = {17735A9D-BFD9-4585-A7CB-3208CA6EA8A7}
|
||||||
{602976C5-2477-4B4C-AD9A-1EAFB250529A} = {ED2FE3E2-F7E7-4389-8231-B65123F2076F}
|
{602976C5-2477-4B4C-AD9A-1EAFB250529A} = {ED2FE3E2-F7E7-4389-8231-B65123F2076F}
|
||||||
{FCDFAF40-CC16-4D49-96C0-E49F195E7142} = {ED2FE3E2-F7E7-4389-8231-B65123F2076F}
|
{FCDFAF40-CC16-4D49-96C0-E49F195E7142} = {ED2FE3E2-F7E7-4389-8231-B65123F2076F}
|
||||||
|
{84BB2DD5-B2D8-4C85-AAF9-29D2A74FBF94} = {88278B81-7649-45DC-8A6A-D3A645C5AFC3}
|
||||||
EndGlobalSection
|
EndGlobalSection
|
||||||
GlobalSection(ExtensibilityGlobals) = postSolution
|
GlobalSection(ExtensibilityGlobals) = postSolution
|
||||||
SolutionGuid = {B526D2CE-EE2D-4AD4-93EF-1867D90FF1F5}
|
SolutionGuid = {B526D2CE-EE2D-4AD4-93EF-1867D90FF1F5}
|
||||||
|
|
|
@ -2,15 +2,15 @@
|
||||||
|
|
||||||
[![.NET Slack Status](https://aspnetcoreslack.herokuapp.com/badge.svg?2)](http://tattoocoder.com/aspnet-slack-sign-up/) [![Join the chat at https://gitter.im/dotnet/cli](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/dotnet/cli?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
|
[![.NET Slack Status](https://aspnetcoreslack.herokuapp.com/badge.svg?2)](http://tattoocoder.com/aspnet-slack-sign-up/) [![Join the chat at https://gitter.im/dotnet/cli](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/dotnet/cli?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
|
||||||
|
|
||||||
This repo contains the source code for cross-platform [.NET Core](http://github.com/dotnet/core) command line toolchain. It contains the implementation of each command, the native packages for various supported platforms as well as documentation.
|
This repo contains the source code for cross-platform [.NET Core](http://github.com/dotnet/core) command line toolchain. It contains the implementation of each command, the native packages for various supported platforms and the documentation.
|
||||||
|
|
||||||
Looking for V1 of the .NET Core tooling?
|
Looking for V1 of the .NET Core tooling?
|
||||||
----------------------------------------
|
----------------------------------------
|
||||||
|
|
||||||
If you are looking for the v1.0.1 release of the .NET Core tools (CLI, MSBuild and the new csproj), head over to https://dot.net/core and download!
|
If you are looking for the v2.0 release of the .NET Core tools (CLI, MSBuild and the new csproj), head over to https://dot.net/core and download!
|
||||||
|
|
||||||
> **Note:** the master branch of the CLI repo is based on the upcoming v2 of .NET Core and is considered pre-release. For production-level usage, use the
|
> **Note:** the master branch of the CLI repo is based on post-v2.0 of .NET Core and is considered pre-release. For production-level usage, use the
|
||||||
> v1 of the tools.
|
> v2.0 of the tools.
|
||||||
|
|
||||||
Found an issue?
|
Found an issue?
|
||||||
---------------
|
---------------
|
||||||
|
|
|
@ -21,12 +21,13 @@
|
||||||
<BackwardsCompatibility110CoreSetupInstallerBlobRootUrl>$(BackwardsCompatibility110CoreSetupBlobRootUrlWithChannel)/Installers</BackwardsCompatibility110CoreSetupInstallerBlobRootUrl>
|
<BackwardsCompatibility110CoreSetupInstallerBlobRootUrl>$(BackwardsCompatibility110CoreSetupBlobRootUrlWithChannel)/Installers</BackwardsCompatibility110CoreSetupInstallerBlobRootUrl>
|
||||||
<BackwardsCompatibility110CoreSetupDownloadDirectory>$(IntermediateDirectory)/coreSetupDownload/$(BackwardsCompatibility110SharedFrameworkVersion)</BackwardsCompatibility110CoreSetupDownloadDirectory>
|
<BackwardsCompatibility110CoreSetupDownloadDirectory>$(IntermediateDirectory)/coreSetupDownload/$(BackwardsCompatibility110SharedFrameworkVersion)</BackwardsCompatibility110CoreSetupDownloadDirectory>
|
||||||
<BackwardsCompatibility110CombinedSharedHostAndFrameworkArchive>$(BackwardsCompatibility110CoreSetupDownloadDirectory)/combinedSharedHostAndFrameworkArchive$(ArchiveExtension)</BackwardsCompatibility110CombinedSharedHostAndFrameworkArchive>
|
<BackwardsCompatibility110CombinedSharedHostAndFrameworkArchive>$(BackwardsCompatibility110CoreSetupDownloadDirectory)/combinedSharedHostAndFrameworkArchive$(ArchiveExtension)</BackwardsCompatibility110CombinedSharedHostAndFrameworkArchive>
|
||||||
|
<CoreSetupBlobAccessTokenParam Condition=" '$(CoreSetupBlobAccessToken)' != '' ">?$(CoreSetupBlobAccessToken)</CoreSetupBlobAccessTokenParam>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<ItemGroup Condition=" '$(IncludeSharedFrameworksForBackwardsCompatibilityTests)' == 'true' ">
|
<ItemGroup Condition=" '$(IncludeSharedFrameworksForBackwardsCompatibilityTests)' == 'true' ">
|
||||||
<_DownloadAndExtractItem Include="BackwardsCompatibility110CombinedSharedHostAndFrameworkArchive"
|
<_DownloadAndExtractItem Include="BackwardsCompatibility110CombinedSharedHostAndFrameworkArchive"
|
||||||
Condition="!Exists('$(BackwardsCompatibility110CombinedSharedHostAndFrameworkArchive)')">
|
Condition="!Exists('$(BackwardsCompatibility110CombinedSharedHostAndFrameworkArchive)')">
|
||||||
<Url>$(BackwardsCompatibility110SharedFrameworkArchiveBlobRootUrl)/$(BackwardsCompatibility110CombinedFrameworkHostCompressedFileName)</Url>
|
<Url>$(BackwardsCompatibility110SharedFrameworkArchiveBlobRootUrl)/$(BackwardsCompatibility110CombinedFrameworkHostCompressedFileName)$(CoreSetupBlobAccessTokenParam)</Url>
|
||||||
<DownloadFileName>$(BackwardsCompatibility110CombinedSharedHostAndFrameworkArchive)</DownloadFileName>
|
<DownloadFileName>$(BackwardsCompatibility110CombinedSharedHostAndFrameworkArchive)</DownloadFileName>
|
||||||
<ExtractDestination>$(BackwardsCompatibleSharedFrameworksPublishDirectory)</ExtractDestination>
|
<ExtractDestination>$(BackwardsCompatibleSharedFrameworksPublishDirectory)</ExtractDestination>
|
||||||
<!-- don't overwrite the destination because there can be multiple shared fx's and they need to be combined -->
|
<!-- don't overwrite the destination because there can be multiple shared fx's and they need to be combined -->
|
||||||
|
@ -35,21 +36,21 @@
|
||||||
|
|
||||||
<_DownloadAndExtractItem Include="BackwardsCompatibility110DownloadedSharedFrameworkInstallerFile"
|
<_DownloadAndExtractItem Include="BackwardsCompatibility110DownloadedSharedFrameworkInstallerFile"
|
||||||
Condition="!Exists('$(BackwardsCompatibility110DownloadedSharedFrameworkInstallerFile)') And '$(OSName)' != 'linux'">
|
Condition="!Exists('$(BackwardsCompatibility110DownloadedSharedFrameworkInstallerFile)') And '$(OSName)' != 'linux'">
|
||||||
<Url>$(BackwardsCompatibility110CoreSetupInstallerBlobRootUrl)/$(BackwardsCompatibility110SharedFrameworkVersion)/$(BackwardsCompatibility110DownloadedSharedFrameworkInstallerFileName)</Url>
|
<Url>$(BackwardsCompatibility110CoreSetupInstallerBlobRootUrl)/$(BackwardsCompatibility110SharedFrameworkVersion)/$(BackwardsCompatibility110DownloadedSharedFrameworkInstallerFileName)$(CoreSetupBlobAccessTokenParam)</Url>
|
||||||
<DownloadFileName>$(BackwardsCompatibility110DownloadedSharedFrameworkInstallerFile)</DownloadFileName>
|
<DownloadFileName>$(BackwardsCompatibility110DownloadedSharedFrameworkInstallerFile)</DownloadFileName>
|
||||||
<ExtractDestination></ExtractDestination>
|
<ExtractDestination></ExtractDestination>
|
||||||
</_DownloadAndExtractItem>
|
</_DownloadAndExtractItem>
|
||||||
|
|
||||||
<_DownloadAndExtractItem Include="BackwardsCompatibility110DownloadedSharedHostInstallerFile"
|
<_DownloadAndExtractItem Include="BackwardsCompatibility110DownloadedSharedHostInstallerFile"
|
||||||
Condition="!Exists('$(BackwardsCompatibility110DownloadedSharedHostInstallerFile)') And '$(OSName)' != 'linux'">
|
Condition="!Exists('$(BackwardsCompatibility110DownloadedSharedHostInstallerFile)') And '$(OSName)' != 'linux'">
|
||||||
<Url>$(BackwardsCompatibility110CoreSetupInstallerBlobRootUrl)/$(BackwardsCompatibility110SharedHostVersion)/$(BackwardsCompatibility110DownloadedSharedHostInstallerFileName)</Url>
|
<Url>$(BackwardsCompatibility110CoreSetupInstallerBlobRootUrl)/$(BackwardsCompatibility110SharedHostVersion)/$(BackwardsCompatibility110DownloadedSharedHostInstallerFileName)$(CoreSetupBlobAccessTokenParam)</Url>
|
||||||
<DownloadFileName>$(BackwardsCompatibility110DownloadedSharedHostInstallerFile)</DownloadFileName>
|
<DownloadFileName>$(BackwardsCompatibility110DownloadedSharedHostInstallerFile)</DownloadFileName>
|
||||||
<ExtractDestintation></ExtractDestintation>
|
<ExtractDestintation></ExtractDestintation>
|
||||||
</_DownloadAndExtractItem>
|
</_DownloadAndExtractItem>
|
||||||
|
|
||||||
<_DownloadAndExtractItem Include="BackwardsCompatibility110DownloadedHostFxrInstallerFile"
|
<_DownloadAndExtractItem Include="BackwardsCompatibility110DownloadedHostFxrInstallerFile"
|
||||||
Condition="!Exists('$(BackwardsCompatibility110DownloadedHostFxrInstallerFile)') And '$(OSName)' != 'linux'">
|
Condition="!Exists('$(BackwardsCompatibility110DownloadedHostFxrInstallerFile)') And '$(OSName)' != 'linux'">
|
||||||
<Url>$(BackwardsCompatibility110CoreSetupInstallerBlobRootUrl)/$(BackwardsCompatibility110HostFxrVersion)/$(BackwardsCompatibility110DownloadedHostFxrInstallerFileName)</Url>
|
<Url>$(BackwardsCompatibility110CoreSetupInstallerBlobRootUrl)/$(BackwardsCompatibility110HostFxrVersion)/$(BackwardsCompatibility110DownloadedHostFxrInstallerFileName)$(CoreSetupBlobAccessTokenParam)</Url>
|
||||||
<DownloadFileName>$(BackwardsCompatibility110DownloadedHostFxrInstallerFile)</DownloadFileName>
|
<DownloadFileName>$(BackwardsCompatibility110DownloadedHostFxrInstallerFile)</DownloadFileName>
|
||||||
<ExtractDestintation></ExtractDestintation>
|
<ExtractDestintation></ExtractDestintation>
|
||||||
</_DownloadAndExtractItem>
|
</_DownloadAndExtractItem>
|
||||||
|
|
|
@ -1,10 +1,10 @@
|
||||||
<Project ToolsVersion="14.0">
|
<Project ToolsVersion="14.0">
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<SdkBrandName>Microsoft .NET Core SDK 2.1.0 - Preview 1</SdkBrandName>
|
<SdkBrandName>Microsoft .NET Core SDK 2.1.0 - Preview</SdkBrandName>
|
||||||
<MSBuildExtensionsBrandName>.NET Standard Support for Visual Studio 2015</MSBuildExtensionsBrandName>
|
<MSBuildExtensionsBrandName>.NET Standard Support for Visual Studio 2015</MSBuildExtensionsBrandName>
|
||||||
<SharedFrameworkBrandName>Microsoft .NET Core Runtime 2.0.0</SharedFrameworkBrandName>
|
<SharedFrameworkBrandName>Microsoft .NET Core Runtime 2.1.0 - Preview</SharedFrameworkBrandName>
|
||||||
<SharedHostBrandName>Microsoft .NET Core Host 2.0.0</SharedHostBrandName>
|
<SharedHostBrandName>Microsoft .NET Core Host 2.1.0 - Preview</SharedHostBrandName>
|
||||||
<HostFxrBrandName>Microsoft .NET Core Host FX Resolver 2.0.0</HostFxrBrandName>
|
<HostFxrBrandName>Microsoft .NET Core Host FX Resolver 2.1.0 - Preview</HostFxrBrandName>
|
||||||
|
|
||||||
<SharedFrameworkName>Microsoft.NETCore.App</SharedFrameworkName>
|
<SharedFrameworkName>Microsoft.NETCore.App</SharedFrameworkName>
|
||||||
<SharedFrameworkNugetName>$(SharedFrameworkName)</SharedFrameworkNugetName>
|
<SharedFrameworkNugetName>$(SharedFrameworkName)</SharedFrameworkNugetName>
|
||||||
|
|
|
@ -25,6 +25,7 @@
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<CoreSetupBlobRootUrl Condition="'$(CoreSetupBlobRootUrl)' == ''">https://dotnetcli.azureedge.net/dotnet/</CoreSetupBlobRootUrl>
|
<CoreSetupBlobRootUrl Condition="'$(CoreSetupBlobRootUrl)' == ''">https://dotnetcli.azureedge.net/dotnet/</CoreSetupBlobRootUrl>
|
||||||
|
<CoreSetupBlobAccessTokenParam Condition=" '$(CoreSetupBlobAccessToken)' != '' ">?$(CoreSetupBlobAccessToken)</CoreSetupBlobAccessTokenParam>
|
||||||
<CoreSetupRootUrl>$(CoreSetupBlobRootUrl)Runtime/</CoreSetupRootUrl>
|
<CoreSetupRootUrl>$(CoreSetupBlobRootUrl)Runtime/</CoreSetupRootUrl>
|
||||||
<CoreSetupDownloadDirectory>$(IntermediateDirectory)/coreSetupDownload/$(SharedFrameworkVersion)</CoreSetupDownloadDirectory>
|
<CoreSetupDownloadDirectory>$(IntermediateDirectory)/coreSetupDownload/$(SharedFrameworkVersion)</CoreSetupDownloadDirectory>
|
||||||
<CombinedSharedHostAndFrameworkArchive>$(CoreSetupDownloadDirectory)/combinedSharedHostAndFrameworkArchive$(ArchiveExtension)</CombinedSharedHostAndFrameworkArchive>
|
<CombinedSharedHostAndFrameworkArchive>$(CoreSetupDownloadDirectory)/combinedSharedHostAndFrameworkArchive$(ArchiveExtension)</CombinedSharedHostAndFrameworkArchive>
|
||||||
|
@ -48,49 +49,49 @@
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<_DownloadAndExtractItem Include="CombinedSharedHostAndFrameworkArchive"
|
<_DownloadAndExtractItem Include="CombinedSharedHostAndFrameworkArchive"
|
||||||
Condition="!Exists('$(CombinedSharedHostAndFrameworkArchive)')">
|
Condition="!Exists('$(CombinedSharedHostAndFrameworkArchive)')">
|
||||||
<Url>$(CoreSetupRootUrl)$(SharedFrameworkVersion)/$(CombinedFrameworkHostCompressedFileName)</Url>
|
<Url>$(CoreSetupRootUrl)$(SharedFrameworkVersion)/$(CombinedFrameworkHostCompressedFileName)$(CoreSetupBlobAccessTokenParam)</Url>
|
||||||
<DownloadFileName>$(CombinedSharedHostAndFrameworkArchive)</DownloadFileName>
|
<DownloadFileName>$(CombinedSharedHostAndFrameworkArchive)</DownloadFileName>
|
||||||
<ExtractDestination>$(SharedFrameworkPublishDirectory)</ExtractDestination>
|
<ExtractDestination>$(SharedFrameworkPublishDirectory)</ExtractDestination>
|
||||||
</_DownloadAndExtractItem>
|
</_DownloadAndExtractItem>
|
||||||
|
|
||||||
<_DownloadAndExtractItem Include="DownloadedSharedFrameworkInstallerFile"
|
<_DownloadAndExtractItem Include="DownloadedSharedFrameworkInstallerFile"
|
||||||
Condition="'$(SkipBuildingInstallers)' != 'true' And !Exists('$(DownloadedSharedFrameworkInstallerFile)') And '$(InstallerExtension)' != ''">
|
Condition="'$(SkipBuildingInstallers)' != 'true' And !Exists('$(DownloadedSharedFrameworkInstallerFile)') And '$(InstallerExtension)' != ''">
|
||||||
<Url>$(CoreSetupRootUrl)$(SharedFrameworkVersion)/$(DownloadedSharedFrameworkInstallerFileName)</Url>
|
<Url>$(CoreSetupRootUrl)$(SharedFrameworkVersion)/$(DownloadedSharedFrameworkInstallerFileName)$(CoreSetupBlobAccessTokenParam)</Url>
|
||||||
<DownloadFileName>$(DownloadedSharedFrameworkInstallerFile)</DownloadFileName>
|
<DownloadFileName>$(DownloadedSharedFrameworkInstallerFile)</DownloadFileName>
|
||||||
<ExtractDestination></ExtractDestination>
|
<ExtractDestination></ExtractDestination>
|
||||||
</_DownloadAndExtractItem>
|
</_DownloadAndExtractItem>
|
||||||
|
|
||||||
<_DownloadAndExtractItem Include="DownloadedSharedHostInstallerFile"
|
<_DownloadAndExtractItem Include="DownloadedSharedHostInstallerFile"
|
||||||
Condition="'$(SkipBuildingInstallers)' != 'true' And !Exists('$(DownloadedSharedHostInstallerFile)') And '$(InstallerExtension)' != ''">
|
Condition="'$(SkipBuildingInstallers)' != 'true' And !Exists('$(DownloadedSharedHostInstallerFile)') And '$(InstallerExtension)' != ''">
|
||||||
<Url>$(CoreSetupRootUrl)$(SharedHostVersion)/$(DownloadedSharedHostInstallerFileName)</Url>
|
<Url>$(CoreSetupRootUrl)$(SharedHostVersion)/$(DownloadedSharedHostInstallerFileName)$(CoreSetupBlobAccessTokenParam)</Url>
|
||||||
<DownloadFileName>$(DownloadedSharedHostInstallerFile)</DownloadFileName>
|
<DownloadFileName>$(DownloadedSharedHostInstallerFile)</DownloadFileName>
|
||||||
<ExtractDestination></ExtractDestination>
|
<ExtractDestination></ExtractDestination>
|
||||||
</_DownloadAndExtractItem>
|
</_DownloadAndExtractItem>
|
||||||
|
|
||||||
<_DownloadAndExtractItem Include="DownloadedHostFxrInstallerFile"
|
<_DownloadAndExtractItem Include="DownloadedHostFxrInstallerFile"
|
||||||
Condition="'$(SkipBuildingInstallers)' != 'true' And !Exists('$(DownloadedHostFxrInstallerFile)') And '$(InstallerExtension)' != ''">
|
Condition="'$(SkipBuildingInstallers)' != 'true' And !Exists('$(DownloadedHostFxrInstallerFile)') And '$(InstallerExtension)' != ''">
|
||||||
<Url>$(CoreSetupRootUrl)$(HostFxrVersion)/$(DownloadedHostFxrInstallerFileName)</Url>
|
<Url>$(CoreSetupRootUrl)$(HostFxrVersion)/$(DownloadedHostFxrInstallerFileName)$(CoreSetupBlobAccessTokenParam)</Url>
|
||||||
<DownloadFileName>$(DownloadedHostFxrInstallerFile)</DownloadFileName>
|
<DownloadFileName>$(DownloadedHostFxrInstallerFile)</DownloadFileName>
|
||||||
<ExtractDestination></ExtractDestination>
|
<ExtractDestination></ExtractDestination>
|
||||||
</_DownloadAndExtractItem>
|
</_DownloadAndExtractItem>
|
||||||
|
|
||||||
<_DownloadAndExtractItem Include="AspNetCoreRuntimeInstallerWixLibFile"
|
<_DownloadAndExtractItem Include="AspNetCoreRuntimeInstallerWixLibFile"
|
||||||
Condition=" '$(AspNetCoreRuntimeInstallerWixLibFile)' != '' And !Exists('$(AspNetCoreRuntimeInstallerWixLibFile)')">
|
Condition=" '$(AspNetCoreRuntimeInstallerWixLibFile)' != '' And !Exists('$(AspNetCoreRuntimeInstallerWixLibFile)')">
|
||||||
<Url>$(AspNetCoreRuntimeInstallerBlobRootUrl)/$(AspNetCoreRuntimeInstallerWixLibFileName)</Url>
|
<Url>$(AspNetCoreRuntimeInstallerBlobRootUrl)/$(AspNetCoreRuntimeInstallerWixLibFileName)$(CoreSetupBlobAccessTokenParam)</Url>
|
||||||
<DownloadFileName>$(AspNetCoreRuntimeInstallerWixLibFile)</DownloadFileName>
|
<DownloadFileName>$(AspNetCoreRuntimeInstallerWixLibFile)</DownloadFileName>
|
||||||
<ExtractDestination></ExtractDestination>
|
<ExtractDestination></ExtractDestination>
|
||||||
</_DownloadAndExtractItem>
|
</_DownloadAndExtractItem>
|
||||||
|
|
||||||
<_DownloadAndExtractItem Include="AspNetCoreRuntimeInstallerArchiveFile"
|
<_DownloadAndExtractItem Include="AspNetCoreRuntimeInstallerArchiveFile"
|
||||||
Condition="!Exists('$(AspNetCoreRuntimeInstallerArchiveFile)')">
|
Condition="!Exists('$(AspNetCoreRuntimeInstallerArchiveFile)')">
|
||||||
<Url>$(AspNetCoreRuntimeInstallerBlobRootUrl)/$(AspNetCoreRuntimeInstallerArchiveFileName)</Url>
|
<Url>$(AspNetCoreRuntimeInstallerBlobRootUrl)/$(AspNetCoreRuntimeInstallerArchiveFileName)$(CoreSetupBlobAccessTokenParam)</Url>
|
||||||
<DownloadFileName>$(AspNetCoreRuntimeInstallerArchiveFile)</DownloadFileName>
|
<DownloadFileName>$(AspNetCoreRuntimeInstallerArchiveFile)</DownloadFileName>
|
||||||
<ExtractDestination>$(AspNetRuntimePackageStorePublishDirectory)</ExtractDestination>
|
<ExtractDestination>$(AspNetRuntimePackageStorePublishDirectory)</ExtractDestination>
|
||||||
</_DownloadAndExtractItem>
|
</_DownloadAndExtractItem>
|
||||||
|
|
||||||
<_DownloadAndExtractItem Include="AspNetCoreSharedRuntimeVersionFile"
|
<_DownloadAndExtractItem Include="AspNetCoreSharedRuntimeVersionFile"
|
||||||
Condition="!Exists('$(AspNetCoreSharedRuntimeVersionFile)')">
|
Condition="!Exists('$(AspNetCoreSharedRuntimeVersionFile)')">
|
||||||
<Url>$(AspNetCoreRuntimeInstallerBlobRootUrl)/$(AspNetCoreSharedRuntimeVersionFileName)</Url>
|
<Url>$(AspNetCoreRuntimeInstallerBlobRootUrl)/$(AspNetCoreSharedRuntimeVersionFileName)$(CoreSetupBlobAccessTokenParam)</Url>
|
||||||
<DownloadFileName>$(AspNetCoreSharedRuntimeVersionFile)</DownloadFileName>
|
<DownloadFileName>$(AspNetCoreSharedRuntimeVersionFile)</DownloadFileName>
|
||||||
<ExtractDestination></ExtractDestination>
|
<ExtractDestination></ExtractDestination>
|
||||||
</_DownloadAndExtractItem>
|
</_DownloadAndExtractItem>
|
||||||
|
|
|
@ -2,9 +2,9 @@
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<BundledTemplate Include="Microsoft.DotNet.Common.ItemTemplates" Version="$(TemplateEngineTemplateVersion)" />
|
<BundledTemplate Include="Microsoft.DotNet.Common.ItemTemplates" Version="$(TemplateEngineTemplateVersion)" />
|
||||||
<BundledTemplate Include="Microsoft.DotNet.Web.ItemTemplates" Version="$(TemplateEngineTemplateVersion)" />
|
<BundledTemplate Include="Microsoft.DotNet.Web.ItemTemplates" Version="$(TemplateEngineTemplateVersion)" />
|
||||||
<BundledTemplate Include="Microsoft.DotNet.Common.ProjectTemplates.2.0" Version="$(TemplateEngineTemplate2_0Version)" />
|
<BundledTemplate Include="Microsoft.DotNet.Common.ProjectTemplates.2.1" Version="$(TemplateEngineTemplate2_0Version)" />
|
||||||
<BundledTemplate Include="Microsoft.DotNet.Test.ProjectTemplates.2.0" Version="$(TemplateEngineTemplateVersion)" />
|
<BundledTemplate Include="Microsoft.DotNet.Test.ProjectTemplates.2.1" Version="$(TemplateEngineTemplateVersion)" />
|
||||||
<BundledTemplate Include="Microsoft.DotNet.Web.ProjectTemplates.2.0" Version="$(TemplateEngineTemplateVersion)" />
|
<BundledTemplate Include="Microsoft.DotNet.Web.ProjectTemplates.2.1" Version="$(TemplateEngineTemplateVersion)" />
|
||||||
<BundledTemplate Include="Microsoft.DotNet.Web.Spa.ProjectTemplates" Version="$(SpaTemplateVersion)" />
|
<BundledTemplate Include="Microsoft.DotNet.Web.Spa.ProjectTemplates" Version="$(SpaTemplateVersion)" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
</Project>
|
</Project>
|
||||||
|
|
|
@ -22,9 +22,9 @@
|
||||||
<SharedFrameworkVersion>$(CLI_SharedFrameworkVersion)</SharedFrameworkVersion>
|
<SharedFrameworkVersion>$(CLI_SharedFrameworkVersion)</SharedFrameworkVersion>
|
||||||
<SharedHostVersion>$(CLI_SharedFrameworkVersion)</SharedHostVersion>
|
<SharedHostVersion>$(CLI_SharedFrameworkVersion)</SharedHostVersion>
|
||||||
<HostFxrVersion>$(CLI_SharedFrameworkVersion)</HostFxrVersion>
|
<HostFxrVersion>$(CLI_SharedFrameworkVersion)</HostFxrVersion>
|
||||||
<TemplateEngineVersion>1.0.0-beta2-20170810-304</TemplateEngineVersion>
|
<TemplateEngineVersion>1.0.0-beta2-20170828-305</TemplateEngineVersion>
|
||||||
<TemplateEngineTemplateVersion>1.0.0-beta2-20170810-304</TemplateEngineTemplateVersion>
|
<TemplateEngineTemplateVersion>1.0.0-beta2-20170828-305</TemplateEngineTemplateVersion>
|
||||||
<TemplateEngineTemplate2_0Version>1.0.0-beta2-20170810-304</TemplateEngineTemplate2_0Version>
|
<TemplateEngineTemplate2_0Version>1.0.0-beta2-20170828-305</TemplateEngineTemplate2_0Version>
|
||||||
<PlatformAbstractionsVersion>2.1.0-preview2-25616-02</PlatformAbstractionsVersion>
|
<PlatformAbstractionsVersion>2.1.0-preview2-25616-02</PlatformAbstractionsVersion>
|
||||||
<DependencyModelVersion>2.1.0-preview2-25616-02</DependencyModelVersion>
|
<DependencyModelVersion>2.1.0-preview2-25616-02</DependencyModelVersion>
|
||||||
<CliCommandLineParserVersion>0.1.1-alpha-167</CliCommandLineParserVersion>
|
<CliCommandLineParserVersion>0.1.1-alpha-167</CliCommandLineParserVersion>
|
||||||
|
|
|
@ -32,6 +32,7 @@
|
||||||
<UsingTask TaskName="TarGzFileExtractToDirectory" AssemblyFile="$(CLIBuildDll)" />
|
<UsingTask TaskName="TarGzFileExtractToDirectory" AssemblyFile="$(CLIBuildDll)" />
|
||||||
<UsingTask TaskName="UpdateVersionsRepo" AssemblyFile="$(CLIBuildDll)"/>
|
<UsingTask TaskName="UpdateVersionsRepo" AssemblyFile="$(CLIBuildDll)"/>
|
||||||
<UsingTask TaskName="UploadToAzure" AssemblyFile="$(CLIBuildDll)"/>
|
<UsingTask TaskName="UploadToAzure" AssemblyFile="$(CLIBuildDll)"/>
|
||||||
|
<UsingTask TaskName="UploadToLinuxPackageRepository" AssemblyFile="$(CLIBuildDll)"/>
|
||||||
<UsingTask TaskName="ZipFileCreateFromDirectory" AssemblyFile="$(CLIBuildDll)"/>
|
<UsingTask TaskName="ZipFileCreateFromDirectory" AssemblyFile="$(CLIBuildDll)"/>
|
||||||
<UsingTask TaskName="ZipFileExtractToDirectory" AssemblyFile="$(CLIBuildDll)"/>
|
<UsingTask TaskName="ZipFileExtractToDirectory" AssemblyFile="$(CLIBuildDll)"/>
|
||||||
</Project>
|
</Project>
|
||||||
|
|
|
@ -6,28 +6,23 @@
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<SdkDebianUploadUrl>$(DotnetBlobRootUrl)/$(Product)/$(FullNugetVersion)/$(DistroSpecificArtifactNameWithVersionCombinedHostHostFxrFrameworkSdk)-$(Architecture)$(InstallerExtension)</SdkDebianUploadUrl>
|
<SdkDebianUploadUrl>$(DotnetBlobRootUrl)/$(Product)/$(FullNugetVersion)/$(DistroSpecificArtifactNameWithVersionCombinedHostHostFxrFrameworkSdk)-$(Architecture)$(InstallerExtension)</SdkDebianUploadUrl>
|
||||||
<DebianUploadJsonFile>$(SdkDebianIntermediateDirectory)/package_upload.json</DebianUploadJsonFile>
|
|
||||||
<DebianRevisionNumber>1</DebianRevisionNumber>
|
|
||||||
|
|
||||||
<DebianUploadJsonContent>
|
|
||||||
{
|
|
||||||
"name":"$(SdkDebianPackageName)",
|
|
||||||
"version":"$(NugetVersion)-$(DebianRevisionNumber)",
|
|
||||||
"repositoryId":"$(REPO_ID)",
|
|
||||||
"sourceUrl": "$(SdkDebianUploadUrl)"
|
|
||||||
}
|
|
||||||
</DebianUploadJsonContent>
|
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<Target Name="PublishDebFilesToDebianRepo" Condition=" '$(IsDebianBaseDistro)' == 'True' AND '$(SkipPublishToDebianRepo)' != 'true' AND '$(IslinuxPortable)' != 'true' ">
|
<Target Name="PublishDebFilesToDebianRepo"
|
||||||
<Error Condition="'$(REPO_ID)' == ''" Text="REPO_ID must be set as an environment variable for debian publishing." />
|
DependsOnTargets="SetupDebProps;"
|
||||||
<Error Condition="'$(REPO_USER)' == ''" Text="REPO_USER must be set as an environment variable for debian publishing." />
|
Condition=" '$(IsDebianBaseDistro)' == 'True' AND '$(SkipPublishToDebianRepo)' != 'true' AND '$(IslinuxPortable)' != 'true' " >
|
||||||
<Error Condition="'$(REPO_PASS)' == ''" Text="REPO_PASS must be set as an environment variable for debian publishing." />
|
<Error Condition="'$(REPO_ID)' == ''" Text="REPO_ID must be set as a MsBuild Property variable for debian publishing." />
|
||||||
<Error Condition="'$(REPO_SERVER)' == ''" Text="REPO_SERVER must be set as an environment variable for debian publishing." />
|
<Error Condition="'$(REPO_USER)' == ''" Text="REPO_USER must be set as a MsBuild Property variable for debian publishing." />
|
||||||
|
<Error Condition="'$(REPO_PASS)' == ''" Text="REPO_PASS must be set as a MsBuild Property variable for debian publishing." />
|
||||||
|
<Error Condition="'$(REPO_SERVER)' == ''" Text="REPO_SERVER must be set as a MsBuild Property variable for debian publishing." />
|
||||||
|
|
||||||
<Delete Files="$(DebianUploadJsonFile)" />
|
<UploadToLinuxPackageRepository
|
||||||
<WriteLinesToFile File="$(DebianUploadJsonFile)" Lines="$(DebianUploadJsonContent)" />
|
Username="$(REPO_USER)"
|
||||||
|
Password='$(REPO_PASS)'
|
||||||
<Exec Command="REPO_PASS=$(REPO_PASS) sh -c '$(RepoRoot)/scripts/publish/repoapi_client.sh -addpkg $(DebianUploadJsonFile)'" />
|
Server='$(REPO_SERVER)'
|
||||||
|
RepositoryId='$(REPO_ID)'
|
||||||
|
PathOfPackageToUpload='$(SdkInstallerFile)'
|
||||||
|
PackageNameInLinuxPackageRepository='$(SdkDebianPackageName)'
|
||||||
|
PackageVersionInLinuxPackageRepository='$(NugetVersion)' />
|
||||||
</Target>
|
</Target>
|
||||||
</Project>
|
</Project>
|
||||||
|
|
|
@ -0,0 +1,92 @@
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using FluentAssertions;
|
||||||
|
using Microsoft.DotNet.Cli.Build.UploadToLinuxPackageRepository;
|
||||||
|
using Xunit;
|
||||||
|
|
||||||
|
namespace dotnet_cli_build.Tests
|
||||||
|
{
|
||||||
|
public class GivenActionAndRetryTimes
|
||||||
|
{
|
||||||
|
public static IEnumerable<Task> NoWaitTimer()
|
||||||
|
{
|
||||||
|
while (true)
|
||||||
|
{
|
||||||
|
yield return Task.CompletedTask;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
[Fact]
|
||||||
|
public void ExponentialRetryShouldProvideIntervalSequence()
|
||||||
|
{
|
||||||
|
ExponentialRetry.Intervals.First().Should().Be(TimeSpan.FromSeconds(5));
|
||||||
|
ExponentialRetry.Intervals.Skip(1).First().Should().Be(TimeSpan.FromSeconds(10));
|
||||||
|
ExponentialRetry.Intervals.Skip(2).First().Should().Be(TimeSpan.FromSeconds(20));
|
||||||
|
ExponentialRetry.Intervals.Skip(3).First().Should().Be(TimeSpan.FromSeconds(40));
|
||||||
|
ExponentialRetry.Intervals.Skip(4).First().Should().Be(TimeSpan.FromSeconds(80));
|
||||||
|
}
|
||||||
|
|
||||||
|
[Fact]
|
||||||
|
public void ExponentialShouldNotRetryAfterFirstSucceess()
|
||||||
|
{
|
||||||
|
var fakeAction = new FakeAction(0);
|
||||||
|
ExponentialRetry.ExecuteWithRetry(
|
||||||
|
fakeAction.Run,
|
||||||
|
s => s == "success",
|
||||||
|
10,
|
||||||
|
NoWaitTimer).Wait();
|
||||||
|
fakeAction.Count.Should().Be(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
[Fact]
|
||||||
|
public void ExponentialShouldRetryUntilSuccess()
|
||||||
|
{
|
||||||
|
var fakeAction = new FakeAction(5);
|
||||||
|
ExponentialRetry.ExecuteWithRetry(
|
||||||
|
fakeAction.Run,
|
||||||
|
s => s == "success",
|
||||||
|
10,
|
||||||
|
NoWaitTimer).Wait();
|
||||||
|
fakeAction.Count.Should().Be(5);
|
||||||
|
}
|
||||||
|
|
||||||
|
[Fact]
|
||||||
|
public void ExponentialShouldThrowAfterMaximumAmountReached()
|
||||||
|
{
|
||||||
|
var fakeAction = new FakeAction(10);
|
||||||
|
Action a = () => ExponentialRetry.ExecuteWithRetry(
|
||||||
|
fakeAction.Run,
|
||||||
|
s => s == "success",
|
||||||
|
5,
|
||||||
|
NoWaitTimer,
|
||||||
|
"testing retry").Wait();
|
||||||
|
a.ShouldThrow<RetryFailedException>()
|
||||||
|
.WithMessage("Retry failed for testing retry after 5 times with result: fail");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public class FakeAction
|
||||||
|
{
|
||||||
|
private readonly int _successAfter;
|
||||||
|
|
||||||
|
public FakeAction(int successAfter)
|
||||||
|
{
|
||||||
|
_successAfter = successAfter;
|
||||||
|
}
|
||||||
|
|
||||||
|
public int Count { get; private set; }
|
||||||
|
|
||||||
|
public Task<string> Run()
|
||||||
|
{
|
||||||
|
if (_successAfter == Count)
|
||||||
|
{
|
||||||
|
return Task.FromResult("success");
|
||||||
|
}
|
||||||
|
|
||||||
|
Count++;
|
||||||
|
return Task.FromResult("fail");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,22 @@
|
||||||
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
|
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), dir.props))\dir.props" />
|
||||||
|
|
||||||
|
<PropertyGroup>
|
||||||
|
<TargetFramework>$(CliTargetFramework)</TargetFramework>
|
||||||
|
<VersionPrefix>1.0.0</VersionPrefix>
|
||||||
|
<AssetTargetFallback>$(AssetTargetFallback);portable-net45+win8+wp8+wpa81</AssetTargetFallback>
|
||||||
|
<IsPackable>false</IsPackable>
|
||||||
|
</PropertyGroup>
|
||||||
|
|
||||||
|
<ItemGroup>
|
||||||
|
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="$(CLI_TestPlatform_Version)" />
|
||||||
|
<PackageReference Include="xunit" Version="2.2.0" />
|
||||||
|
<PackageReference Include="xunit.runner.visualstudio" Version="2.2.0" />
|
||||||
|
<PackageReference Include="FluentAssertions" Version="4.18.0" />
|
||||||
|
</ItemGroup>
|
||||||
|
|
||||||
|
<ItemGroup>
|
||||||
|
<ProjectReference Include="..\dotnet-cli-build\dotnet-cli-build.csproj" />
|
||||||
|
</ItemGroup>
|
||||||
|
|
||||||
|
</Project>
|
|
@ -56,7 +56,6 @@ namespace Microsoft.DotNet.Cli.Build
|
||||||
{ "rhel_7_x64", false },
|
{ "rhel_7_x64", false },
|
||||||
{ "ubuntu_14_04_x64", false },
|
{ "ubuntu_14_04_x64", false },
|
||||||
{ "ubuntu_16_04_x64", false },
|
{ "ubuntu_16_04_x64", false },
|
||||||
{ "ubuntu_16_10_x64", false },
|
|
||||||
{ "linux_x64", false }
|
{ "linux_x64", false }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,62 @@
|
||||||
|
// Licensed to the .NET Foundation under one or more agreements.
|
||||||
|
// The .NET Foundation licenses this file to you under the MIT license.
|
||||||
|
// See the LICENSE file in the project root for more information.
|
||||||
|
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Net.Http;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using NuGet.Protocol;
|
||||||
|
|
||||||
|
namespace Microsoft.DotNet.Cli.Build.UploadToLinuxPackageRepository
|
||||||
|
{
|
||||||
|
internal class AddPackageStrategy : IAzurelinuxRepositoryServiceHttpStrategy
|
||||||
|
{
|
||||||
|
private readonly IdInRepositoryService _idInRepositoryService;
|
||||||
|
private readonly string _packageName;
|
||||||
|
private readonly string _packageVersion;
|
||||||
|
private readonly string _repositoryId;
|
||||||
|
|
||||||
|
public AddPackageStrategy(
|
||||||
|
IdInRepositoryService idInRepositoryService,
|
||||||
|
string packageName,
|
||||||
|
string packageVersion,
|
||||||
|
string repositoryId)
|
||||||
|
{
|
||||||
|
_idInRepositoryService = idInRepositoryService
|
||||||
|
?? throw new ArgumentNullException(nameof(idInRepositoryService));
|
||||||
|
_packageName = packageName;
|
||||||
|
_packageVersion = packageVersion;
|
||||||
|
_repositoryId = repositoryId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public async Task<string> Execute(HttpClient client, Uri baseAddress)
|
||||||
|
{
|
||||||
|
var debianUploadJsonContent = new Dictionary<string, string>
|
||||||
|
{
|
||||||
|
["name"] = _packageName,
|
||||||
|
["version"] = AppendDebianRevisionNumber(_packageVersion),
|
||||||
|
["fileId"] = _idInRepositoryService.Id,
|
||||||
|
["repositoryId"] = _repositoryId
|
||||||
|
}.ToJson();
|
||||||
|
var content = new StringContent(debianUploadJsonContent,
|
||||||
|
Encoding.UTF8,
|
||||||
|
"application/json");
|
||||||
|
|
||||||
|
using (var response = await client.PostAsync(new Uri(baseAddress, "/v1/packages"), content))
|
||||||
|
{
|
||||||
|
if (!response.IsSuccessStatusCode)
|
||||||
|
throw new FailedToAddPackageToPackageRepositoryException(
|
||||||
|
$"request:{debianUploadJsonContent} response:{response.ToJson()}");
|
||||||
|
return response.Headers.GetValues("Location").Single();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private static string AppendDebianRevisionNumber(string packageVersion)
|
||||||
|
{
|
||||||
|
return packageVersion + "-1";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,53 @@
|
||||||
|
// Licensed to the .NET Foundation under one or more agreements.
|
||||||
|
// The .NET Foundation licenses this file to you under the MIT license.
|
||||||
|
// See the LICENSE file in the project root for more information.
|
||||||
|
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace Microsoft.DotNet.Cli.Build.UploadToLinuxPackageRepository
|
||||||
|
{
|
||||||
|
public static class ExponentialRetry
|
||||||
|
{
|
||||||
|
public static IEnumerable<TimeSpan> Intervals
|
||||||
|
{
|
||||||
|
get
|
||||||
|
{
|
||||||
|
var seconds = 5;
|
||||||
|
while (true)
|
||||||
|
{
|
||||||
|
yield return TimeSpan.FromSeconds(seconds);
|
||||||
|
seconds *= 2;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public static async Task ExecuteWithRetry(Func<Task<string>> action,
|
||||||
|
Func<string, bool> isSuccess,
|
||||||
|
int maxRetryCount,
|
||||||
|
Func<IEnumerable<Task>> timer,
|
||||||
|
string taskDescription = "")
|
||||||
|
{
|
||||||
|
var count = 0;
|
||||||
|
foreach (var t in timer())
|
||||||
|
{
|
||||||
|
await t;
|
||||||
|
var result = await action();
|
||||||
|
if (isSuccess(result))
|
||||||
|
return;
|
||||||
|
count++;
|
||||||
|
if (count == maxRetryCount)
|
||||||
|
throw new RetryFailedException(
|
||||||
|
$"Retry failed for {taskDescription} after {count} times with result: {result}");
|
||||||
|
}
|
||||||
|
throw new Exception("Timer should not be exhausted");
|
||||||
|
}
|
||||||
|
|
||||||
|
public static IEnumerable<Task> Timer(IEnumerable<TimeSpan> interval)
|
||||||
|
{
|
||||||
|
return interval.Select(Task.Delay);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,24 @@
|
||||||
|
// Licensed to the .NET Foundation under one or more agreements.
|
||||||
|
// The .NET Foundation licenses this file to you under the MIT license.
|
||||||
|
// See the LICENSE file in the project root for more information.
|
||||||
|
|
||||||
|
using System;
|
||||||
|
|
||||||
|
namespace Microsoft.DotNet.Cli.Build.UploadToLinuxPackageRepository
|
||||||
|
{
|
||||||
|
public class FailedToAddPackageToPackageRepositoryException : Exception
|
||||||
|
{
|
||||||
|
public FailedToAddPackageToPackageRepositoryException(string message) : base(message)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
public FailedToAddPackageToPackageRepositoryException()
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
public FailedToAddPackageToPackageRepositoryException(string message, Exception innerException) : base(message,
|
||||||
|
innerException)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,49 @@
|
||||||
|
// Licensed to the .NET Foundation under one or more agreements.
|
||||||
|
// The .NET Foundation licenses this file to you under the MIT license.
|
||||||
|
// See the LICENSE file in the project root for more information.
|
||||||
|
|
||||||
|
using System;
|
||||||
|
using System.IO;
|
||||||
|
using System.Net.Http;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using NuGet.Protocol;
|
||||||
|
|
||||||
|
namespace Microsoft.DotNet.Cli.Build.UploadToLinuxPackageRepository
|
||||||
|
{
|
||||||
|
internal class FileUploadStrategy : IAzurelinuxRepositoryServiceHttpStrategy
|
||||||
|
{
|
||||||
|
private readonly string _pathToPackageToUpload;
|
||||||
|
|
||||||
|
public FileUploadStrategy(string pathToPackageToUpload)
|
||||||
|
{
|
||||||
|
_pathToPackageToUpload = pathToPackageToUpload
|
||||||
|
?? throw new ArgumentNullException(nameof(pathToPackageToUpload));
|
||||||
|
}
|
||||||
|
|
||||||
|
public async Task<string> Execute(HttpClient client, Uri baseAddress)
|
||||||
|
{
|
||||||
|
var fileName = Path.GetFileName(_pathToPackageToUpload);
|
||||||
|
|
||||||
|
using (var content =
|
||||||
|
new MultipartFormDataContent())
|
||||||
|
{
|
||||||
|
var url = new Uri(baseAddress, "/v1/files");
|
||||||
|
content.Add(
|
||||||
|
new StreamContent(
|
||||||
|
new MemoryStream(
|
||||||
|
File.ReadAllBytes(_pathToPackageToUpload))),
|
||||||
|
"file",
|
||||||
|
fileName);
|
||||||
|
using (var message = await client.PostAsync(url, content))
|
||||||
|
{
|
||||||
|
if (!message.IsSuccessStatusCode)
|
||||||
|
{
|
||||||
|
throw new FailedToAddPackageToPackageRepositoryException(
|
||||||
|
$"{message.ToJson()} failed to post file to {url} file name:{fileName} pathToPackageToUpload:{_pathToPackageToUpload}");
|
||||||
|
}
|
||||||
|
return await message.Content.ReadAsStringAsync();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,15 @@
|
||||||
|
// Licensed to the .NET Foundation under one or more agreements.
|
||||||
|
// The .NET Foundation licenses this file to you under the MIT license.
|
||||||
|
// See the LICENSE file in the project root for more information.
|
||||||
|
|
||||||
|
using System;
|
||||||
|
using System.Net.Http;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace Microsoft.DotNet.Cli.Build.UploadToLinuxPackageRepository
|
||||||
|
{
|
||||||
|
internal interface IAzurelinuxRepositoryServiceHttpStrategy
|
||||||
|
{
|
||||||
|
Task<string> Execute(HttpClient client, Uri baseAddress);
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,18 @@
|
||||||
|
// Licensed to the .NET Foundation under one or more agreements.
|
||||||
|
// The .NET Foundation licenses this file to you under the MIT license.
|
||||||
|
// See the LICENSE file in the project root for more information.
|
||||||
|
|
||||||
|
using System;
|
||||||
|
|
||||||
|
namespace Microsoft.DotNet.Cli.Build.UploadToLinuxPackageRepository
|
||||||
|
{
|
||||||
|
internal class IdInRepositoryService
|
||||||
|
{
|
||||||
|
public IdInRepositoryService(string id)
|
||||||
|
{
|
||||||
|
Id = id ?? throw new ArgumentNullException(nameof(id));
|
||||||
|
}
|
||||||
|
|
||||||
|
public string Id { get; }
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,38 @@
|
||||||
|
// Licensed to the .NET Foundation under one or more agreements.
|
||||||
|
// The .NET Foundation licenses this file to you under the MIT license.
|
||||||
|
// See the LICENSE file in the project root for more information.
|
||||||
|
|
||||||
|
using System;
|
||||||
|
|
||||||
|
namespace Microsoft.DotNet.Cli.Build.UploadToLinuxPackageRepository
|
||||||
|
{
|
||||||
|
internal class LinuxPackageRepositoryDestiny
|
||||||
|
{
|
||||||
|
private readonly string _password;
|
||||||
|
private readonly string _server;
|
||||||
|
private readonly string _username;
|
||||||
|
|
||||||
|
public LinuxPackageRepositoryDestiny(string username,
|
||||||
|
string password,
|
||||||
|
string server,
|
||||||
|
string repositoryId)
|
||||||
|
{
|
||||||
|
_username = username ?? throw new ArgumentNullException(nameof(username));
|
||||||
|
_password = password ?? throw new ArgumentNullException(nameof(password));
|
||||||
|
_server = server ?? throw new ArgumentNullException(nameof(server));
|
||||||
|
RepositoryId = repositoryId ?? throw new ArgumentNullException(nameof(repositoryId));
|
||||||
|
}
|
||||||
|
|
||||||
|
public string RepositoryId { get; }
|
||||||
|
|
||||||
|
public Uri GetBaseAddress()
|
||||||
|
{
|
||||||
|
return new Uri($"https://{_server}");
|
||||||
|
}
|
||||||
|
|
||||||
|
public string GetSimpleAuth()
|
||||||
|
{
|
||||||
|
return $"{_username}:{_password}";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,46 @@
|
||||||
|
// Licensed to the .NET Foundation under one or more agreements.
|
||||||
|
// The .NET Foundation licenses this file to you under the MIT license.
|
||||||
|
// See the LICENSE file in the project root for more information.
|
||||||
|
|
||||||
|
using System;
|
||||||
|
using System.Net.Http;
|
||||||
|
using System.Net.Http.Headers;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace Microsoft.DotNet.Cli.Build.UploadToLinuxPackageRepository
|
||||||
|
{
|
||||||
|
internal class LinuxPackageRepositoryHttpPrepare
|
||||||
|
{
|
||||||
|
private readonly IAzurelinuxRepositoryServiceHttpStrategy _httpStrategy;
|
||||||
|
private readonly LinuxPackageRepositoryDestiny _linuxPackageRepositoryDestiny;
|
||||||
|
|
||||||
|
public LinuxPackageRepositoryHttpPrepare(
|
||||||
|
LinuxPackageRepositoryDestiny linuxPackageRepositoryDestiny,
|
||||||
|
IAzurelinuxRepositoryServiceHttpStrategy httpStrategy
|
||||||
|
)
|
||||||
|
{
|
||||||
|
_linuxPackageRepositoryDestiny = linuxPackageRepositoryDestiny
|
||||||
|
?? throw new ArgumentNullException(nameof(linuxPackageRepositoryDestiny));
|
||||||
|
_httpStrategy = httpStrategy ?? throw new ArgumentNullException(nameof(httpStrategy));
|
||||||
|
}
|
||||||
|
|
||||||
|
public async Task<string> RemoteCall()
|
||||||
|
{
|
||||||
|
using (var handler = new HttpClientHandler())
|
||||||
|
{
|
||||||
|
using (var client = new HttpClient(handler))
|
||||||
|
{
|
||||||
|
var authHeader =
|
||||||
|
Convert.ToBase64String(Encoding.UTF8.GetBytes((string) _linuxPackageRepositoryDestiny.GetSimpleAuth()));
|
||||||
|
client.DefaultRequestHeaders.Authorization =
|
||||||
|
new AuthenticationHeaderValue("Basic", authHeader);
|
||||||
|
client.DefaultRequestHeaders.Accept.Add(new MediaTypeWithQualityHeaderValue("application/json"));
|
||||||
|
client.Timeout = TimeSpan.FromMinutes(10);
|
||||||
|
|
||||||
|
return await _httpStrategy.Execute(client, _linuxPackageRepositoryDestiny.GetBaseAddress());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,34 @@
|
||||||
|
// Licensed to the .NET Foundation under one or more agreements.
|
||||||
|
// The .NET Foundation licenses this file to you under the MIT license.
|
||||||
|
// See the LICENSE file in the project root for more information.
|
||||||
|
|
||||||
|
using System;
|
||||||
|
using System.Net.Http;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using Newtonsoft.Json.Linq;
|
||||||
|
|
||||||
|
namespace Microsoft.DotNet.Cli.Build.UploadToLinuxPackageRepository
|
||||||
|
{
|
||||||
|
internal class PullQueuedPackageStatus : IAzurelinuxRepositoryServiceHttpStrategy
|
||||||
|
{
|
||||||
|
private readonly QueueResourceLocation _queueResourceLocation;
|
||||||
|
|
||||||
|
public PullQueuedPackageStatus(QueueResourceLocation queueResourceLocation)
|
||||||
|
{
|
||||||
|
_queueResourceLocation = queueResourceLocation
|
||||||
|
?? throw new ArgumentNullException(nameof(queueResourceLocation));
|
||||||
|
}
|
||||||
|
|
||||||
|
public async Task<string> Execute(HttpClient client, Uri baseAddress)
|
||||||
|
{
|
||||||
|
using (var response = await client.GetAsync(new Uri(baseAddress, _queueResourceLocation.Location)))
|
||||||
|
{
|
||||||
|
if (!response.IsSuccessStatusCode)
|
||||||
|
throw new FailedToAddPackageToPackageRepositoryException(
|
||||||
|
"Failed to make request to " + _queueResourceLocation.Location);
|
||||||
|
var body = await response.Content.ReadAsStringAsync();
|
||||||
|
return !body.Contains("status") ? "" : JObject.Parse(body)["status"].ToString();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,18 @@
|
||||||
|
// Licensed to the .NET Foundation under one or more agreements.
|
||||||
|
// The .NET Foundation licenses this file to you under the MIT license.
|
||||||
|
// See the LICENSE file in the project root for more information.
|
||||||
|
|
||||||
|
using System;
|
||||||
|
|
||||||
|
namespace Microsoft.DotNet.Cli.Build.UploadToLinuxPackageRepository
|
||||||
|
{
|
||||||
|
internal class QueueResourceLocation
|
||||||
|
{
|
||||||
|
public QueueResourceLocation(string location)
|
||||||
|
{
|
||||||
|
Location = location ?? throw new ArgumentNullException(nameof(location));
|
||||||
|
}
|
||||||
|
|
||||||
|
public string Location { get; }
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,23 @@
|
||||||
|
// Licensed to the .NET Foundation under one or more agreements.
|
||||||
|
// The .NET Foundation licenses this file to you under the MIT license.
|
||||||
|
// See the LICENSE file in the project root for more information.
|
||||||
|
|
||||||
|
using System;
|
||||||
|
|
||||||
|
namespace Microsoft.DotNet.Cli.Build.UploadToLinuxPackageRepository
|
||||||
|
{
|
||||||
|
public class RetryFailedException : Exception
|
||||||
|
{
|
||||||
|
public RetryFailedException(string message) : base(message)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
public RetryFailedException()
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
public RetryFailedException(string message, Exception innerException) : base(message, innerException)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,121 @@
|
||||||
|
// Licensed to the .NET Foundation under one or more agreements.
|
||||||
|
// The .NET Foundation licenses this file to you under the MIT license.
|
||||||
|
// See the LICENSE file in the project root for more information.
|
||||||
|
|
||||||
|
using System;
|
||||||
|
using System.Net.Http;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using Microsoft.Build.Framework;
|
||||||
|
using Newtonsoft.Json.Linq;
|
||||||
|
using Task = Microsoft.Build.Utilities.Task;
|
||||||
|
|
||||||
|
namespace Microsoft.DotNet.Cli.Build.UploadToLinuxPackageRepository
|
||||||
|
{
|
||||||
|
public class UploadToLinuxPackageRepository : Task
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// The Azure repository service user name.
|
||||||
|
/// </summary>
|
||||||
|
[Required]
|
||||||
|
public string Username { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// The Azure repository service Password.
|
||||||
|
/// </summary>
|
||||||
|
[Required]
|
||||||
|
public string Password { get; set; }
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// The Azure repository service URL ex: "tux-devrepo.corp.microsoft.com".
|
||||||
|
/// </summary>
|
||||||
|
[Required]
|
||||||
|
public string Server { get; set; }
|
||||||
|
|
||||||
|
[Required]
|
||||||
|
public string RepositoryId { get; set; }
|
||||||
|
|
||||||
|
[Required]
|
||||||
|
public string PathOfPackageToUpload { get; set; }
|
||||||
|
|
||||||
|
[Required]
|
||||||
|
public string PackageNameInLinuxPackageRepository { get; set; }
|
||||||
|
|
||||||
|
|
||||||
|
[Required]
|
||||||
|
public string PackageVersionInLinuxPackageRepository { get; set; }
|
||||||
|
|
||||||
|
|
||||||
|
public override bool Execute()
|
||||||
|
{
|
||||||
|
ExecuteAsyncWithRetry().GetAwaiter().GetResult();
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
private async System.Threading.Tasks.Task ExecuteAsyncWithRetry()
|
||||||
|
{
|
||||||
|
await ExponentialRetry.ExecuteWithRetry(
|
||||||
|
UploadAndAddpackageAndEnsureItIsReady,
|
||||||
|
s => s == "",
|
||||||
|
maxRetryCount: 3,
|
||||||
|
timer: () => ExponentialRetry.Timer(ExponentialRetry.Intervals),
|
||||||
|
taskDescription: $"running {nameof(UploadAndAddpackageAndEnsureItIsReady)}");
|
||||||
|
}
|
||||||
|
|
||||||
|
private async Task<string> UploadAndAddpackageAndEnsureItIsReady()
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
Log.LogMessage(
|
||||||
|
MessageImportance.High,
|
||||||
|
"Begin uploading Linux Package to feed service, RepositoryId {0}, Server {1}, Package to upload {2}.",
|
||||||
|
RepositoryId,
|
||||||
|
Server,
|
||||||
|
PathOfPackageToUpload);
|
||||||
|
|
||||||
|
var linuxPackageRepositoryDestiny =
|
||||||
|
new LinuxPackageRepositoryDestiny(Username, Password, Server, RepositoryId);
|
||||||
|
var uploadResponse = await new LinuxPackageRepositoryHttpPrepare(
|
||||||
|
linuxPackageRepositoryDestiny,
|
||||||
|
new FileUploadStrategy(PathOfPackageToUpload)).RemoteCall();
|
||||||
|
|
||||||
|
var idInRepositoryService = new IdInRepositoryService(JObject.Parse(uploadResponse)["id"].ToString());
|
||||||
|
|
||||||
|
var addPackageResponse = await new LinuxPackageRepositoryHttpPrepare(
|
||||||
|
linuxPackageRepositoryDestiny,
|
||||||
|
new AddPackageStrategy(
|
||||||
|
idInRepositoryService,
|
||||||
|
PackageNameInLinuxPackageRepository,
|
||||||
|
PackageVersionInLinuxPackageRepository,
|
||||||
|
linuxPackageRepositoryDestiny.RepositoryId)).RemoteCall();
|
||||||
|
|
||||||
|
var queueResourceLocation = new QueueResourceLocation(addPackageResponse);
|
||||||
|
|
||||||
|
Func<Task<string>> pullQueuedPackageStatus = new LinuxPackageRepositoryHttpPrepare(
|
||||||
|
linuxPackageRepositoryDestiny,
|
||||||
|
new PullQueuedPackageStatus(queueResourceLocation)).RemoteCall;
|
||||||
|
|
||||||
|
await ExponentialRetry.ExecuteWithRetry(
|
||||||
|
pullQueuedPackageStatus,
|
||||||
|
s => s == "fileReady",
|
||||||
|
5,
|
||||||
|
() => ExponentialRetry.Timer(ExponentialRetry.Intervals),
|
||||||
|
$"PullQueuedPackageStatus location: {queueResourceLocation.Location}");
|
||||||
|
|
||||||
|
Log.LogMessage(
|
||||||
|
MessageImportance.High,
|
||||||
|
"Upload to feed service is completed, queue resource location {0}",
|
||||||
|
queueResourceLocation.Location);
|
||||||
|
|
||||||
|
return "";
|
||||||
|
}
|
||||||
|
catch (FailedToAddPackageToPackageRepositoryException e)
|
||||||
|
{
|
||||||
|
return e.ToString();
|
||||||
|
}
|
||||||
|
catch (HttpRequestException e)
|
||||||
|
{
|
||||||
|
return e.ToString();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
|
@ -9,7 +9,7 @@ def project = GithubProject
|
||||||
def branch = GithubBranchName
|
def branch = GithubBranchName
|
||||||
def isPR = true
|
def isPR = true
|
||||||
|
|
||||||
def platformList = ['Linux:x64:Release', 'Debian8.2:x64:Debug', 'Ubuntu:x64:Release', 'Ubuntu16.04:x64:Debug', 'Ubuntu16.10:x64:Debug', 'OSX10.12:x64:Release', 'Windows_NT:x64:Release', 'Windows_NT:x86:Debug', 'RHEL7.2:x64:Release', 'CentOS7.1:x64:Debug', 'OpenSUSE42.1:x64:Debug']
|
def platformList = ['Linux:x64:Release', 'Debian8.2:x64:Debug', 'Ubuntu:x64:Release', 'Ubuntu16.04:x64:Debug', 'OSX10.12:x64:Release', 'Windows_NT:x64:Release', 'Windows_NT:x86:Debug', 'RHEL7.2:x64:Release', 'CentOS7.1:x64:Debug']
|
||||||
|
|
||||||
def static getBuildJobName(def configuration, def os, def architecture) {
|
def static getBuildJobName(def configuration, def os, def architecture) {
|
||||||
return configuration.toLowerCase() + '_' + os.toLowerCase() + '_' + architecture.toLowerCase()
|
return configuration.toLowerCase() + '_' + os.toLowerCase() + '_' + architecture.toLowerCase()
|
||||||
|
|
|
@ -15,7 +15,7 @@ try {
|
||||||
if (Test-Path $stage2) {
|
if (Test-Path $stage2) {
|
||||||
$env:PATH="$stage2;$env:PATH"
|
$env:PATH="$stage2;$env:PATH"
|
||||||
} else {
|
} else {
|
||||||
Write-Output "You don't have a dev build in the 'artifacts\$rid\stage2' folder!"
|
Write-Host "You don't have a dev build in the 'artifacts\$rid\stage2' folder!"
|
||||||
}
|
}
|
||||||
|
|
||||||
dotnet @args
|
dotnet @args
|
||||||
|
|
25
scripts/obtain/dotnet-install.ps1
vendored
25
scripts/obtain/dotnet-install.ps1
vendored
|
@ -58,6 +58,9 @@
|
||||||
.PARAMETER ProxyUseDefaultCredentials
|
.PARAMETER ProxyUseDefaultCredentials
|
||||||
Default: false
|
Default: false
|
||||||
Use default credentials, when using proxy address.
|
Use default credentials, when using proxy address.
|
||||||
|
.PARAMETER SkipNonVersionedFiles
|
||||||
|
Default: false
|
||||||
|
Skips installing non-versioned files if they already exist, such as dotnet.exe.
|
||||||
#>
|
#>
|
||||||
[cmdletbinding()]
|
[cmdletbinding()]
|
||||||
param(
|
param(
|
||||||
|
@ -71,7 +74,8 @@ param(
|
||||||
[string]$AzureFeed="https://dotnetcli.azureedge.net/dotnet",
|
[string]$AzureFeed="https://dotnetcli.azureedge.net/dotnet",
|
||||||
[string]$UncachedFeed="https://dotnetcli.blob.core.windows.net/dotnet",
|
[string]$UncachedFeed="https://dotnetcli.blob.core.windows.net/dotnet",
|
||||||
[string]$ProxyAddress,
|
[string]$ProxyAddress,
|
||||||
[switch]$ProxyUseDefaultCredentials
|
[switch]$ProxyUseDefaultCredentials,
|
||||||
|
[switch]$SkipNonVersionedFiles
|
||||||
)
|
)
|
||||||
|
|
||||||
Set-StrictMode -Version Latest
|
Set-StrictMode -Version Latest
|
||||||
|
@ -82,10 +86,10 @@ $BinFolderRelativePath=""
|
||||||
|
|
||||||
# example path with regex: shared/1.0.0-beta-12345/somepath
|
# example path with regex: shared/1.0.0-beta-12345/somepath
|
||||||
$VersionRegEx="/\d+\.\d+[^/]+/"
|
$VersionRegEx="/\d+\.\d+[^/]+/"
|
||||||
$OverrideNonVersionedFiles=$true
|
$OverrideNonVersionedFiles = !$SkipNonVersionedFiles
|
||||||
|
|
||||||
function Say($str) {
|
function Say($str) {
|
||||||
Write-Output "dotnet-install: $str"
|
Write-Host "dotnet-install: $str"
|
||||||
}
|
}
|
||||||
|
|
||||||
function Say-Verbose($str) {
|
function Say-Verbose($str) {
|
||||||
|
@ -260,7 +264,7 @@ function Get-Specific-Version-From-Version([string]$AzureFeed, [string]$Channel,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function Get-Download-Link([string]$AzureFeed, [string]$Channel, [string]$SpecificVersion, [string]$CLIArchitecture) {
|
function Get-Download-Link([string]$AzureFeed, [string]$SpecificVersion, [string]$CLIArchitecture) {
|
||||||
Say-Invocation $MyInvocation
|
Say-Invocation $MyInvocation
|
||||||
|
|
||||||
if ($SharedRuntime) {
|
if ($SharedRuntime) {
|
||||||
|
@ -275,7 +279,7 @@ function Get-Download-Link([string]$AzureFeed, [string]$Channel, [string]$Specif
|
||||||
return $PayloadURL
|
return $PayloadURL
|
||||||
}
|
}
|
||||||
|
|
||||||
function Get-LegacyDownload-Link([string]$AzureFeed, [string]$Channel, [string]$SpecificVersion, [string]$CLIArchitecture) {
|
function Get-LegacyDownload-Link([string]$AzureFeed, [string]$SpecificVersion, [string]$CLIArchitecture) {
|
||||||
Say-Invocation $MyInvocation
|
Say-Invocation $MyInvocation
|
||||||
|
|
||||||
if ($SharedRuntime) {
|
if ($SharedRuntime) {
|
||||||
|
@ -445,14 +449,14 @@ function Prepend-Sdk-InstallRoot-To-Path([string]$InstallRoot, [string]$BinFolde
|
||||||
|
|
||||||
$CLIArchitecture = Get-CLIArchitecture-From-Architecture $Architecture
|
$CLIArchitecture = Get-CLIArchitecture-From-Architecture $Architecture
|
||||||
$SpecificVersion = Get-Specific-Version-From-Version -AzureFeed $AzureFeed -Channel $Channel -Version $Version
|
$SpecificVersion = Get-Specific-Version-From-Version -AzureFeed $AzureFeed -Channel $Channel -Version $Version
|
||||||
$DownloadLink = Get-Download-Link -AzureFeed $AzureFeed -Channel $Channel -SpecificVersion $SpecificVersion -CLIArchitecture $CLIArchitecture
|
$DownloadLink = Get-Download-Link -AzureFeed $AzureFeed -SpecificVersion $SpecificVersion -CLIArchitecture $CLIArchitecture
|
||||||
$LegacyDownloadLink = Get-LegacyDownload-Link -AzureFeed $AzureFeed -Channel $Channel -SpecificVersion $SpecificVersion -CLIArchitecture $CLIArchitecture
|
$LegacyDownloadLink = Get-LegacyDownload-Link -AzureFeed $AzureFeed -SpecificVersion $SpecificVersion -CLIArchitecture $CLIArchitecture
|
||||||
|
|
||||||
if ($DryRun) {
|
if ($DryRun) {
|
||||||
Say "Payload URLs:"
|
Say "Payload URLs:"
|
||||||
Say "Primary - $DownloadLink"
|
Say "Primary - $DownloadLink"
|
||||||
Say "Legacy - $LegacyDownloadLink"
|
Say "Legacy - $LegacyDownloadLink"
|
||||||
Say "Repeatable invocation: .\$($MyInvocation.MyCommand) -Version $SpecificVersion -Channel $Channel -Architecture $CLIArchitecture -InstallDir $InstallDir"
|
Say "Repeatable invocation: .\$($MyInvocation.Line)"
|
||||||
exit 0
|
exit 0
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -470,14 +474,13 @@ if ($IsSdkInstalled) {
|
||||||
New-Item -ItemType Directory -Force -Path $InstallRoot | Out-Null
|
New-Item -ItemType Directory -Force -Path $InstallRoot | Out-Null
|
||||||
|
|
||||||
$installDrive = $((Get-Item $InstallRoot).PSDrive.Name);
|
$installDrive = $((Get-Item $InstallRoot).PSDrive.Name);
|
||||||
Write-Output "${installDrive}:";
|
|
||||||
$free = Get-CimInstance -Class win32_logicaldisk | where Deviceid -eq "${installDrive}:"
|
$free = Get-CimInstance -Class win32_logicaldisk | where Deviceid -eq "${installDrive}:"
|
||||||
if ($free.Freespace / 1MB -le 100 ) {
|
if ($free.Freespace / 1MB -le 100 ) {
|
||||||
Say "There is not enough disk space on drive ${installDrive}:"
|
Say "There is not enough disk space on drive ${installDrive}:"
|
||||||
exit 0
|
exit 0
|
||||||
}
|
}
|
||||||
|
|
||||||
$ZipPath = [System.IO.Path]::GetTempFileName()
|
$ZipPath = [System.IO.Path]::combine([System.IO.Path]::GetTempPath(), [System.IO.Path]::GetRandomFileName())
|
||||||
Say-Verbose "Zip path: $ZipPath"
|
Say-Verbose "Zip path: $ZipPath"
|
||||||
Say "Downloading link: $DownloadLink"
|
Say "Downloading link: $DownloadLink"
|
||||||
try {
|
try {
|
||||||
|
@ -486,7 +489,7 @@ try {
|
||||||
catch {
|
catch {
|
||||||
Say "Cannot download: $DownloadLink"
|
Say "Cannot download: $DownloadLink"
|
||||||
$DownloadLink = $LegacyDownloadLink
|
$DownloadLink = $LegacyDownloadLink
|
||||||
$ZipPath = [System.IO.Path]::GetTempFileName()
|
$ZipPath = [System.IO.Path]::combine([System.IO.Path]::GetTempPath(), [System.IO.Path]::GetRandomFileName())
|
||||||
Say-Verbose "Legacy zip path: $ZipPath"
|
Say-Verbose "Legacy zip path: $ZipPath"
|
||||||
Say "Downloading legacy link: $DownloadLink"
|
Say "Downloading legacy link: $DownloadLink"
|
||||||
DownloadFile -Uri $DownloadLink -OutPath $ZipPath
|
DownloadFile -Uri $DownloadLink -OutPath $ZipPath
|
||||||
|
|
13
scripts/obtain/dotnet-install.sh
vendored
13
scripts/obtain/dotnet-install.sh
vendored
|
@ -194,6 +194,7 @@ check_pre_reqs() {
|
||||||
[ -z "$($LDCONFIG_COMMAND -p | grep libunwind)" ] && say_err "Unable to locate libunwind. Install libunwind to continue" && failing=true
|
[ -z "$($LDCONFIG_COMMAND -p | grep libunwind)" ] && say_err "Unable to locate libunwind. Install libunwind to continue" && failing=true
|
||||||
[ -z "$($LDCONFIG_COMMAND -p | grep libssl)" ] && say_err "Unable to locate libssl. Install libssl to continue" && failing=true
|
[ -z "$($LDCONFIG_COMMAND -p | grep libssl)" ] && say_err "Unable to locate libssl. Install libssl to continue" && failing=true
|
||||||
[ -z "$($LDCONFIG_COMMAND -p | grep libicu)" ] && say_err "Unable to locate libicu. Install libicu to continue" && failing=true
|
[ -z "$($LDCONFIG_COMMAND -p | grep libicu)" ] && say_err "Unable to locate libicu. Install libicu to continue" && failing=true
|
||||||
|
[ -z "$($LDCONFIG_COMMAND -p | grep -F libcurl.so)" ] && say_err "Unable to locate libcurl. Install libcurl to continue" && failing=true
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ "$failing" = true ]; then
|
if [ "$failing" = true ]; then
|
||||||
|
@ -333,6 +334,7 @@ is_dotnet_package_installed() {
|
||||||
# azure_feed - $1
|
# azure_feed - $1
|
||||||
# channel - $2
|
# channel - $2
|
||||||
# normalized_architecture - $3
|
# normalized_architecture - $3
|
||||||
|
# coherent - $4
|
||||||
get_latest_version_info() {
|
get_latest_version_info() {
|
||||||
eval $invocation
|
eval $invocation
|
||||||
|
|
||||||
|
@ -541,7 +543,7 @@ extract_dotnet_package() {
|
||||||
|
|
||||||
local folders_with_version_regex='^.*/[0-9]+\.[0-9]+[^/]+/'
|
local folders_with_version_regex='^.*/[0-9]+\.[0-9]+[^/]+/'
|
||||||
find $temp_out_path -type f | grep -Eo $folders_with_version_regex | copy_files_or_dirs_from_list $temp_out_path $out_path false
|
find $temp_out_path -type f | grep -Eo $folders_with_version_regex | copy_files_or_dirs_from_list $temp_out_path $out_path false
|
||||||
find $temp_out_path -type f | grep -Ev $folders_with_version_regex | copy_files_or_dirs_from_list $temp_out_path $out_path true
|
find $temp_out_path -type f | grep -Ev $folders_with_version_regex | copy_files_or_dirs_from_list $temp_out_path $out_path $override_non_versioned_files
|
||||||
|
|
||||||
rm -rf $temp_out_path
|
rm -rf $temp_out_path
|
||||||
|
|
||||||
|
@ -600,7 +602,7 @@ downloadwget() {
|
||||||
|
|
||||||
local failed=false
|
local failed=false
|
||||||
if [ -z "$out_path" ]; then
|
if [ -z "$out_path" ]; then
|
||||||
wget -q --tries 10 $remote_path || failed=true
|
wget -q --tries 10 -O - $remote_path || failed=true
|
||||||
else
|
else
|
||||||
wget -v --tries 10 -O $out_path $remote_path || failed=true
|
wget -v --tries 10 -O $out_path $remote_path || failed=true
|
||||||
fi
|
fi
|
||||||
|
@ -687,6 +689,7 @@ uncached_feed="https://dotnetcli.blob.core.windows.net/dotnet"
|
||||||
verbose=false
|
verbose=false
|
||||||
shared_runtime=false
|
shared_runtime=false
|
||||||
runtime_id=""
|
runtime_id=""
|
||||||
|
override_non_versioned_files=true
|
||||||
|
|
||||||
while [ $# -ne 0 ]
|
while [ $# -ne 0 ]
|
||||||
do
|
do
|
||||||
|
@ -732,6 +735,10 @@ do
|
||||||
shift
|
shift
|
||||||
runtime_id="$1"
|
runtime_id="$1"
|
||||||
;;
|
;;
|
||||||
|
--skip-non-versioned-files|-[Ss]kip[Nn]on[Vv]ersioned[Ff]iles)
|
||||||
|
shift
|
||||||
|
override_non_versioned_files=false
|
||||||
|
;;
|
||||||
-?|--?|-h|--help|-[Hh]elp)
|
-?|--?|-h|--help|-[Hh]elp)
|
||||||
script_name="$(basename $0)"
|
script_name="$(basename $0)"
|
||||||
echo ".NET Tools Installer"
|
echo ".NET Tools Installer"
|
||||||
|
@ -764,6 +771,8 @@ do
|
||||||
echo " --arch,-Architecture,-Arch"
|
echo " --arch,-Architecture,-Arch"
|
||||||
echo " --shared-runtime Installs just the shared runtime bits, not the entire SDK."
|
echo " --shared-runtime Installs just the shared runtime bits, not the entire SDK."
|
||||||
echo " -SharedRuntime"
|
echo " -SharedRuntime"
|
||||||
|
echo " --skip-non-versioned-files Skips non-versioned files if they already exist, such as the dotnet executable."
|
||||||
|
echo " -SkipNonVersionedFiles"
|
||||||
echo " --dry-run,-DryRun Do not perform installation. Display download link."
|
echo " --dry-run,-DryRun Do not perform installation. Display download link."
|
||||||
echo " --no-path, -NoPath Do not set PATH for the current process."
|
echo " --no-path, -NoPath Do not set PATH for the current process."
|
||||||
echo " --verbose,-Verbose Display diagnostics information."
|
echo " --verbose,-Verbose Display diagnostics information."
|
||||||
|
|
|
@ -1,194 +0,0 @@
|
||||||
#!/bin/bash
|
|
||||||
#
|
|
||||||
# Copyright (c) .NET Foundation and contributors. All rights reserved.
|
|
||||||
# Licensed under the MIT license. See LICENSE file in the project root for full license information.
|
|
||||||
#
|
|
||||||
|
|
||||||
# This is a VERY basic script for Create/Delete operations on repos and packages
|
|
||||||
#
|
|
||||||
# Environment Dependencies:
|
|
||||||
# $REPO_SERVER
|
|
||||||
# $REPO_USER
|
|
||||||
# $REPO_PASS
|
|
||||||
|
|
||||||
cmd=$1
|
|
||||||
urls=urls.txt
|
|
||||||
defaultPackageFile=new_package.json
|
|
||||||
defaultRepoFile=new_repo.json
|
|
||||||
repositoryId=$REPO_ID
|
|
||||||
server=$REPO_SERVER
|
|
||||||
user=$REPO_USER
|
|
||||||
pass=$REPO_PASS
|
|
||||||
protocol=https
|
|
||||||
port=443
|
|
||||||
baseurl="$protocol://$user:$pass@$server:$port"
|
|
||||||
|
|
||||||
echo $baseurl
|
|
||||||
|
|
||||||
function BailIf
|
|
||||||
{
|
|
||||||
if [ $1 -ne 0 ]; then
|
|
||||||
echo "Failure occurred communicating with $server"
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
# List packages, using $1 as a regex to filter results
|
|
||||||
function ListPackages
|
|
||||||
{
|
|
||||||
curl -k "$baseurl/v1/packages" | sed 's/{/\n{/g' | egrep "$1" | sed 's/,/,\n/g' | sed 's/^"/\t"/g'
|
|
||||||
echo ""
|
|
||||||
}
|
|
||||||
|
|
||||||
# Create a new Repo using the specified JSON file
|
|
||||||
function AddRepo
|
|
||||||
{
|
|
||||||
repoFile=$1
|
|
||||||
if [ -z $repoFile ]; then
|
|
||||||
echo "Error: Must specify a JSON-formatted file. Reference $defaultRepoFile.template"
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
if [ ! -f $repoFile ]; then
|
|
||||||
echo "Error: Cannot create repo - $repoFile does not exist"
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
packageUrl=$(grep "url" $repoFile | head -n 1 | awk '{print $2}' | tr -d ',')
|
|
||||||
echo "Creating new repo on $server [$packageUrl]"
|
|
||||||
curl -i -k "$baseurl/v1/repositories" --data @./$repoFile -H "Content-Type: application/json"
|
|
||||||
BailIf $?
|
|
||||||
echo ""
|
|
||||||
}
|
|
||||||
|
|
||||||
# Upload a single package using the specified JSON file
|
|
||||||
function AddPackage
|
|
||||||
{
|
|
||||||
packageFile=$1
|
|
||||||
if [ -z $packageFile ]; then
|
|
||||||
echo "Error: Must specify a JSON-formatted file. Reference $defaultPackageFile.template"
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
if [ ! -f $packageFile ]; then
|
|
||||||
echo "Error: Cannot add package - $packageFile does not exist"
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
packageUrl=$(grep "sourceUrl" $packageFile | head -n 1 | awk '{print $2}')
|
|
||||||
echo "Adding package to $server [$packageUrl]"
|
|
||||||
curl -i -k "$baseurl/v1/packages" --data @$packageFile -H "Content-Type: application/json"
|
|
||||||
BailIf $?
|
|
||||||
echo ""
|
|
||||||
}
|
|
||||||
|
|
||||||
# Upload a single package by dynamically creating a JSON file using a provided URL
|
|
||||||
function AddPackageByUrl
|
|
||||||
{
|
|
||||||
# Parse URL
|
|
||||||
url=$(echo "$1")
|
|
||||||
if [ -z $url ]; then
|
|
||||||
return
|
|
||||||
fi
|
|
||||||
escapedUrl=$(echo "$url" | sed 's/\//\\\//g')
|
|
||||||
set -- "$1"
|
|
||||||
oldIFS=$IFS
|
|
||||||
IFS="/"; declare -a splitUrl=($*)
|
|
||||||
index=${#splitUrl[@]}
|
|
||||||
let "index -= 1"
|
|
||||||
filename=${splitUrl[$index]}
|
|
||||||
set -- "$filename"
|
|
||||||
IFS="_"; declare -a splitFile=($*)
|
|
||||||
IFS=$oldIFS
|
|
||||||
pkgName=${splitFile[0]}
|
|
||||||
pkgVer=${splitFile[1]}
|
|
||||||
if [ -z $pkgName ] || [ -z $pkgVer ]; then
|
|
||||||
echo "ERROR parsing $url"
|
|
||||||
return
|
|
||||||
fi
|
|
||||||
# Create Package .json file
|
|
||||||
cp $defaultPackageFile.template $defaultPackageFile
|
|
||||||
sed -i "s/PACKAGENAME/$pkgName/g" $defaultPackageFile
|
|
||||||
sed -i "s/PACKAGEVERSION/$pkgVer/g" $defaultPackageFile
|
|
||||||
sed -i "s/PACKAGEURL/$escapedUrl/g" $defaultPackageFile
|
|
||||||
sed -i "s/REPOSITORYID/$repositoryId/g" $defaultPackageFile
|
|
||||||
# Test that URL is ok
|
|
||||||
wget -q --spider "$url"
|
|
||||||
if [[ $? -eq 0 ]]; then
|
|
||||||
echo "Ready to upload $pkgName [$pkgVer]"
|
|
||||||
else
|
|
||||||
echo "ERROR testing URL $url"
|
|
||||||
return
|
|
||||||
fi
|
|
||||||
# Perform Upload
|
|
||||||
AddPackage $defaultPackageFile
|
|
||||||
# Cleanup
|
|
||||||
# rm $defaultPackageFile
|
|
||||||
}
|
|
||||||
|
|
||||||
# Upload multiple packages by reading urls line-by-line from the specified file
|
|
||||||
function AddPackages
|
|
||||||
{
|
|
||||||
urlFile=$1
|
|
||||||
if [ -z $urlFile ]; then
|
|
||||||
echo "Error: Must specify a flat text file containing one or more URLs"
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
if [ ! -f $urlFile ]; then
|
|
||||||
echo "Error: Cannot add packages. File $urlFile does not exist"
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
for url in $(cat $urlFile); do
|
|
||||||
AddPackageByUrl "$url"
|
|
||||||
sleep 5
|
|
||||||
done
|
|
||||||
}
|
|
||||||
|
|
||||||
# Delete the specified repo
|
|
||||||
function DeleteRepo
|
|
||||||
{
|
|
||||||
repoId=$1
|
|
||||||
if [ -z $repoId ]; then
|
|
||||||
echo "Error: Please specify repository ID. Run -listrepos for a list of IDs"
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
curl -I -k -X DELETE "$baseurl/v1/repositories/$repoId"
|
|
||||||
BailIf $?
|
|
||||||
}
|
|
||||||
|
|
||||||
# Delete the specified package
|
|
||||||
function DeletePackage
|
|
||||||
{
|
|
||||||
packageId=$1
|
|
||||||
if [ -z $packageId ]; then
|
|
||||||
echo "Error: Please specify package ID. Run -listpkgs for a list of IDs"
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
echo Removing pkgId $packageId from repo $repositoryId
|
|
||||||
curl -I -k -X DELETE "$baseurl/v1/packages/$packageId"
|
|
||||||
BailIf $?
|
|
||||||
}
|
|
||||||
|
|
||||||
if [[ "$1" == "-listrepos" ]]; then
|
|
||||||
echo "Fetching repo list from $server..."
|
|
||||||
curl -k "$baseurl/v1/repositories" | sed 's/,/,\n/g' | sed 's/^"/\t"/g'
|
|
||||||
echo ""
|
|
||||||
elif [[ "$1" == "-listpkgs" ]]; then
|
|
||||||
echo "Fetching package list from $server"
|
|
||||||
ListPackages $2
|
|
||||||
elif [[ "$1" == "-addrepo" ]]; then
|
|
||||||
AddRepo $2
|
|
||||||
elif [[ "$1" == "-addpkg" ]]; then
|
|
||||||
AddPackage $2
|
|
||||||
elif [[ "$1" == "-addpkgs" ]]; then
|
|
||||||
AddPackages $2
|
|
||||||
elif [[ "$1" == "-delrepo" ]]; then
|
|
||||||
DeleteRepo $2
|
|
||||||
elif [[ "$1" == "-delpkg" ]]; then
|
|
||||||
DeletePackage $2
|
|
||||||
else
|
|
||||||
echo "USAGE: ./repotool.sh -OPTION"
|
|
||||||
echo "-listrepos: Gather a list of repos"
|
|
||||||
echo "-listpkgs: Gather a list of packages"
|
|
||||||
echo "-addrepo [FILENAME] : Create a new repo using the specified JSON file"
|
|
||||||
echo "-addpkg [FILENAME] : Add package to repo using the specified JSON file"
|
|
||||||
echo "-addpkgs [FILENAME] : Add packages to repo using urls contained in FILENAME"
|
|
||||||
echo "-delrepo REPOID : Delete the specified repo by ID"
|
|
||||||
echo "-delpkg PKGID : Delete the specified package by ID"
|
|
||||||
fi
|
|
|
@ -12,5 +12,5 @@ if (Test-Path $stage2) {
|
||||||
$env:PATH="$stage2;$env:PATH"
|
$env:PATH="$stage2;$env:PATH"
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
Write-Output "You don't have a dev build in the 'artifacts\win10-x64\stage2' folder!"
|
Write-Host "You don't have a dev build in the 'artifacts\win10-x64\stage2' folder!"
|
||||||
}
|
}
|
||||||
|
|
|
@ -27,6 +27,8 @@ path-to-application:
|
||||||
nuget {LocalizableStrings.NugetDefinition}
|
nuget {LocalizableStrings.NugetDefinition}
|
||||||
msbuild {LocalizableStrings.MsBuildDefinition}
|
msbuild {LocalizableStrings.MsBuildDefinition}
|
||||||
vstest {LocalizableStrings.VsTestDefinition}
|
vstest {LocalizableStrings.VsTestDefinition}
|
||||||
|
store {LocalizableStrings.StoreDefinition}
|
||||||
|
help {LocalizableStrings.HelpDefinition}
|
||||||
|
|
||||||
{LocalizableStrings.CommonOptions}:
|
{LocalizableStrings.CommonOptions}:
|
||||||
-v|--verbosity {CommonLocalizableStrings.VerbosityOptionDescription}
|
-v|--verbosity {CommonLocalizableStrings.VerbosityOptionDescription}
|
||||||
|
|
|
@ -180,6 +180,9 @@
|
||||||
<data name="MigrateDefinition" xml:space="preserve">
|
<data name="MigrateDefinition" xml:space="preserve">
|
||||||
<value>Migrates a project.json based project to a msbuild based project.</value>
|
<value>Migrates a project.json based project to a msbuild based project.</value>
|
||||||
</data>
|
</data>
|
||||||
|
<data name="StoreDefinition" xml:space="preserve">
|
||||||
|
<value>Stores the specified assemblies in the runtime store.</value>
|
||||||
|
</data>
|
||||||
<data name="ProjectModificationCommands" xml:space="preserve">
|
<data name="ProjectModificationCommands" xml:space="preserve">
|
||||||
<value>Project modification commands</value>
|
<value>Project modification commands</value>
|
||||||
</data>
|
</data>
|
||||||
|
|
|
@ -237,6 +237,11 @@
|
||||||
<target state="needs-review-translation">Cesta k dodatečnému souboru deps.json.</target>
|
<target state="needs-review-translation">Cesta k dodatečnému souboru deps.json.</target>
|
||||||
<note />
|
<note />
|
||||||
</trans-unit>
|
</trans-unit>
|
||||||
|
<trans-unit id="StoreDefinition">
|
||||||
|
<source>Stores the specified assemblies in the runtime store.</source>
|
||||||
|
<target state="new">Stores the specified assemblies in the runtime store.</target>
|
||||||
|
<note />
|
||||||
|
</trans-unit>
|
||||||
</body>
|
</body>
|
||||||
</file>
|
</file>
|
||||||
</xliff>
|
</xliff>
|
|
@ -237,6 +237,11 @@
|
||||||
<target state="needs-review-translation">Pfad zur zusätzlichen "deps.json"-Datei.</target>
|
<target state="needs-review-translation">Pfad zur zusätzlichen "deps.json"-Datei.</target>
|
||||||
<note />
|
<note />
|
||||||
</trans-unit>
|
</trans-unit>
|
||||||
|
<trans-unit id="StoreDefinition">
|
||||||
|
<source>Stores the specified assemblies in the runtime store.</source>
|
||||||
|
<target state="new">Stores the specified assemblies in the runtime store.</target>
|
||||||
|
<note />
|
||||||
|
</trans-unit>
|
||||||
</body>
|
</body>
|
||||||
</file>
|
</file>
|
||||||
</xliff>
|
</xliff>
|
|
@ -237,6 +237,11 @@
|
||||||
<target state="needs-review-translation">Ruta de acceso al archivo deps.json adicional.</target>
|
<target state="needs-review-translation">Ruta de acceso al archivo deps.json adicional.</target>
|
||||||
<note />
|
<note />
|
||||||
</trans-unit>
|
</trans-unit>
|
||||||
|
<trans-unit id="StoreDefinition">
|
||||||
|
<source>Stores the specified assemblies in the runtime store.</source>
|
||||||
|
<target state="new">Stores the specified assemblies in the runtime store.</target>
|
||||||
|
<note />
|
||||||
|
</trans-unit>
|
||||||
</body>
|
</body>
|
||||||
</file>
|
</file>
|
||||||
</xliff>
|
</xliff>
|
|
@ -237,6 +237,11 @@
|
||||||
<target state="needs-review-translation">Chemin du fichier deps.json supplémentaire.</target>
|
<target state="needs-review-translation">Chemin du fichier deps.json supplémentaire.</target>
|
||||||
<note />
|
<note />
|
||||||
</trans-unit>
|
</trans-unit>
|
||||||
|
<trans-unit id="StoreDefinition">
|
||||||
|
<source>Stores the specified assemblies in the runtime store.</source>
|
||||||
|
<target state="new">Stores the specified assemblies in the runtime store.</target>
|
||||||
|
<note />
|
||||||
|
</trans-unit>
|
||||||
</body>
|
</body>
|
||||||
</file>
|
</file>
|
||||||
</xliff>
|
</xliff>
|
|
@ -237,6 +237,11 @@
|
||||||
<target state="needs-review-translation">Percorso del file deps.json aggiuntivo.</target>
|
<target state="needs-review-translation">Percorso del file deps.json aggiuntivo.</target>
|
||||||
<note />
|
<note />
|
||||||
</trans-unit>
|
</trans-unit>
|
||||||
|
<trans-unit id="StoreDefinition">
|
||||||
|
<source>Stores the specified assemblies in the runtime store.</source>
|
||||||
|
<target state="new">Stores the specified assemblies in the runtime store.</target>
|
||||||
|
<note />
|
||||||
|
</trans-unit>
|
||||||
</body>
|
</body>
|
||||||
</file>
|
</file>
|
||||||
</xliff>
|
</xliff>
|
|
@ -237,6 +237,11 @@
|
||||||
<target state="needs-review-translation">追加 deps.json ファイルへのパス。</target>
|
<target state="needs-review-translation">追加 deps.json ファイルへのパス。</target>
|
||||||
<note />
|
<note />
|
||||||
</trans-unit>
|
</trans-unit>
|
||||||
|
<trans-unit id="StoreDefinition">
|
||||||
|
<source>Stores the specified assemblies in the runtime store.</source>
|
||||||
|
<target state="new">Stores the specified assemblies in the runtime store.</target>
|
||||||
|
<note />
|
||||||
|
</trans-unit>
|
||||||
</body>
|
</body>
|
||||||
</file>
|
</file>
|
||||||
</xliff>
|
</xliff>
|
|
@ -237,6 +237,11 @@
|
||||||
<target state="needs-review-translation">추가 deps.json 파일의 경로입니다.</target>
|
<target state="needs-review-translation">추가 deps.json 파일의 경로입니다.</target>
|
||||||
<note />
|
<note />
|
||||||
</trans-unit>
|
</trans-unit>
|
||||||
|
<trans-unit id="StoreDefinition">
|
||||||
|
<source>Stores the specified assemblies in the runtime store.</source>
|
||||||
|
<target state="new">Stores the specified assemblies in the runtime store.</target>
|
||||||
|
<note />
|
||||||
|
</trans-unit>
|
||||||
</body>
|
</body>
|
||||||
</file>
|
</file>
|
||||||
</xliff>
|
</xliff>
|
|
@ -237,6 +237,11 @@
|
||||||
<target state="needs-review-translation">Ścieżka do dodatkowego pliku deps.json.</target>
|
<target state="needs-review-translation">Ścieżka do dodatkowego pliku deps.json.</target>
|
||||||
<note />
|
<note />
|
||||||
</trans-unit>
|
</trans-unit>
|
||||||
|
<trans-unit id="StoreDefinition">
|
||||||
|
<source>Stores the specified assemblies in the runtime store.</source>
|
||||||
|
<target state="new">Stores the specified assemblies in the runtime store.</target>
|
||||||
|
<note />
|
||||||
|
</trans-unit>
|
||||||
</body>
|
</body>
|
||||||
</file>
|
</file>
|
||||||
</xliff>
|
</xliff>
|
|
@ -237,6 +237,11 @@
|
||||||
<target state="needs-review-translation">Caminho para o arquivo deps.json adicional.</target>
|
<target state="needs-review-translation">Caminho para o arquivo deps.json adicional.</target>
|
||||||
<note />
|
<note />
|
||||||
</trans-unit>
|
</trans-unit>
|
||||||
|
<trans-unit id="StoreDefinition">
|
||||||
|
<source>Stores the specified assemblies in the runtime store.</source>
|
||||||
|
<target state="new">Stores the specified assemblies in the runtime store.</target>
|
||||||
|
<note />
|
||||||
|
</trans-unit>
|
||||||
</body>
|
</body>
|
||||||
</file>
|
</file>
|
||||||
</xliff>
|
</xliff>
|
|
@ -237,6 +237,11 @@
|
||||||
<target state="needs-review-translation">Путь к дополнительному файлу deps.json.</target>
|
<target state="needs-review-translation">Путь к дополнительному файлу deps.json.</target>
|
||||||
<note />
|
<note />
|
||||||
</trans-unit>
|
</trans-unit>
|
||||||
|
<trans-unit id="StoreDefinition">
|
||||||
|
<source>Stores the specified assemblies in the runtime store.</source>
|
||||||
|
<target state="new">Stores the specified assemblies in the runtime store.</target>
|
||||||
|
<note />
|
||||||
|
</trans-unit>
|
||||||
</body>
|
</body>
|
||||||
</file>
|
</file>
|
||||||
</xliff>
|
</xliff>
|
|
@ -237,6 +237,11 @@
|
||||||
<target state="needs-review-translation">Ek deps.json dosyasının yolu.</target>
|
<target state="needs-review-translation">Ek deps.json dosyasının yolu.</target>
|
||||||
<note />
|
<note />
|
||||||
</trans-unit>
|
</trans-unit>
|
||||||
|
<trans-unit id="StoreDefinition">
|
||||||
|
<source>Stores the specified assemblies in the runtime store.</source>
|
||||||
|
<target state="new">Stores the specified assemblies in the runtime store.</target>
|
||||||
|
<note />
|
||||||
|
</trans-unit>
|
||||||
</body>
|
</body>
|
||||||
</file>
|
</file>
|
||||||
</xliff>
|
</xliff>
|
|
@ -237,6 +237,11 @@
|
||||||
<target state="needs-review-translation">其他 deps.json 文件的路径。</target>
|
<target state="needs-review-translation">其他 deps.json 文件的路径。</target>
|
||||||
<note />
|
<note />
|
||||||
</trans-unit>
|
</trans-unit>
|
||||||
|
<trans-unit id="StoreDefinition">
|
||||||
|
<source>Stores the specified assemblies in the runtime store.</source>
|
||||||
|
<target state="new">Stores the specified assemblies in the runtime store.</target>
|
||||||
|
<note />
|
||||||
|
</trans-unit>
|
||||||
</body>
|
</body>
|
||||||
</file>
|
</file>
|
||||||
</xliff>
|
</xliff>
|
|
@ -237,6 +237,11 @@
|
||||||
<target state="needs-review-translation">其他 deps.json 檔案的路徑。</target>
|
<target state="needs-review-translation">其他 deps.json 檔案的路徑。</target>
|
||||||
<note />
|
<note />
|
||||||
</trans-unit>
|
</trans-unit>
|
||||||
|
<trans-unit id="StoreDefinition">
|
||||||
|
<source>Stores the specified assemblies in the runtime store.</source>
|
||||||
|
<target state="new">Stores the specified assemblies in the runtime store.</target>
|
||||||
|
<note />
|
||||||
|
</trans-unit>
|
||||||
</body>
|
</body>
|
||||||
</file>
|
</file>
|
||||||
</xliff>
|
</xliff>
|
|
@ -162,7 +162,9 @@
|
||||||
</data>
|
</data>
|
||||||
<data name="CmdLoggerDescription" xml:space="preserve">
|
<data name="CmdLoggerDescription" xml:space="preserve">
|
||||||
<value>Specify a logger for test results.
|
<value>Specify a logger for test results.
|
||||||
Example: --logger "trx[;LogFileName=<Defaults to unique file name>]"
|
Examples:
|
||||||
|
Log in trx format using a unqiue file name: --logger trx
|
||||||
|
Log in trx format using the specified file name: --logger "trx;LogFileName=<TestResults.trx>"
|
||||||
More info on logger arguments support:https://aka.ms/vstest-report</value>
|
More info on logger arguments support:https://aka.ms/vstest-report</value>
|
||||||
</data>
|
</data>
|
||||||
<data name="CmdConfiguration" xml:space="preserve">
|
<data name="CmdConfiguration" xml:space="preserve">
|
||||||
|
|
|
@ -73,9 +73,11 @@
|
||||||
</trans-unit>
|
</trans-unit>
|
||||||
<trans-unit id="CmdLoggerDescription">
|
<trans-unit id="CmdLoggerDescription">
|
||||||
<source>Specify a logger for test results.
|
<source>Specify a logger for test results.
|
||||||
Example: --logger "trx[;LogFileName=<Defaults to unique file name>]"
|
Examples:
|
||||||
|
Log in trx format using a unqiue file name: --logger trx
|
||||||
|
Log in trx format using the specified file name: --logger "trx;LogFileName=<TestResults.trx>"
|
||||||
More info on logger arguments support:https://aka.ms/vstest-report</source>
|
More info on logger arguments support:https://aka.ms/vstest-report</source>
|
||||||
<target state="translated">Zadejte protokolovací nástroj pro výsledky testů.
|
<target state="needs-review-translation">Zadejte protokolovací nástroj pro výsledky testů.
|
||||||
Příklad: --logger "trx[;LogFileName=<Standardně se nastaví jedinečný název souboru>]"
|
Příklad: --logger "trx[;LogFileName=<Standardně se nastaví jedinečný název souboru>]"
|
||||||
Další informace o podpoře argumentů protokolovacího nástroje: https://aka.ms/vstest-report</target>
|
Další informace o podpoře argumentů protokolovacího nástroje: https://aka.ms/vstest-report</target>
|
||||||
<note />
|
<note />
|
||||||
|
|
|
@ -73,9 +73,11 @@
|
||||||
</trans-unit>
|
</trans-unit>
|
||||||
<trans-unit id="CmdLoggerDescription">
|
<trans-unit id="CmdLoggerDescription">
|
||||||
<source>Specify a logger for test results.
|
<source>Specify a logger for test results.
|
||||||
Example: --logger "trx[;LogFileName=<Defaults to unique file name>]"
|
Examples:
|
||||||
|
Log in trx format using a unqiue file name: --logger trx
|
||||||
|
Log in trx format using the specified file name: --logger "trx;LogFileName=<TestResults.trx>"
|
||||||
More info on logger arguments support:https://aka.ms/vstest-report</source>
|
More info on logger arguments support:https://aka.ms/vstest-report</source>
|
||||||
<target state="translated">Geben Sie eine Protokollierung für Testergebnisse an.
|
<target state="needs-review-translation">Geben Sie eine Protokollierung für Testergebnisse an.
|
||||||
Beispiel: --logger "trx[;LogFileName=<Standardmäßig der eindeutige Dateiname>]"
|
Beispiel: --logger "trx[;LogFileName=<Standardmäßig der eindeutige Dateiname>]"
|
||||||
Weitere Informationen zur Unterstützung von Protokollierungsargumenten: https://aka.ms/vstest-report</target>
|
Weitere Informationen zur Unterstützung von Protokollierungsargumenten: https://aka.ms/vstest-report</target>
|
||||||
<note />
|
<note />
|
||||||
|
|
|
@ -73,9 +73,11 @@
|
||||||
</trans-unit>
|
</trans-unit>
|
||||||
<trans-unit id="CmdLoggerDescription">
|
<trans-unit id="CmdLoggerDescription">
|
||||||
<source>Specify a logger for test results.
|
<source>Specify a logger for test results.
|
||||||
Example: --logger "trx[;LogFileName=<Defaults to unique file name>]"
|
Examples:
|
||||||
|
Log in trx format using a unqiue file name: --logger trx
|
||||||
|
Log in trx format using the specified file name: --logger "trx;LogFileName=<TestResults.trx>"
|
||||||
More info on logger arguments support:https://aka.ms/vstest-report</source>
|
More info on logger arguments support:https://aka.ms/vstest-report</source>
|
||||||
<target state="translated">Especifica un registrador para los resultados de prueba.
|
<target state="needs-review-translation">Especifica un registrador para los resultados de prueba.
|
||||||
Ejemplo: --logger "trx[;LogFileName=<Adopta como valor predeterminado un nombre de archivo único>]"
|
Ejemplo: --logger "trx[;LogFileName=<Adopta como valor predeterminado un nombre de archivo único>]"
|
||||||
Más información sobre la compatibilidad con los argumentos de registrador: https://aka.ms/vstest-report</target>
|
Más información sobre la compatibilidad con los argumentos de registrador: https://aka.ms/vstest-report</target>
|
||||||
<note />
|
<note />
|
||||||
|
|
|
@ -73,9 +73,11 @@
|
||||||
</trans-unit>
|
</trans-unit>
|
||||||
<trans-unit id="CmdLoggerDescription">
|
<trans-unit id="CmdLoggerDescription">
|
||||||
<source>Specify a logger for test results.
|
<source>Specify a logger for test results.
|
||||||
Example: --logger "trx[;LogFileName=<Defaults to unique file name>]"
|
Examples:
|
||||||
|
Log in trx format using a unqiue file name: --logger trx
|
||||||
|
Log in trx format using the specified file name: --logger "trx;LogFileName=<TestResults.trx>"
|
||||||
More info on logger arguments support:https://aka.ms/vstest-report</source>
|
More info on logger arguments support:https://aka.ms/vstest-report</source>
|
||||||
<target state="translated">Spécifiez un enregistreur d'événements pour les résultats des tests.
|
<target state="needs-review-translation">Spécifiez un enregistreur d'événements pour les résultats des tests.
|
||||||
Exemple : --logger "trx[;LogFileName=<Nom de fichier unique par défaut>]"
|
Exemple : --logger "trx[;LogFileName=<Nom de fichier unique par défaut>]"
|
||||||
En savoir plus sur la prise en charge des arguments de l'enregistreur d'événements : https://aka.ms/vstest-report</target>
|
En savoir plus sur la prise en charge des arguments de l'enregistreur d'événements : https://aka.ms/vstest-report</target>
|
||||||
<note />
|
<note />
|
||||||
|
|
|
@ -73,9 +73,11 @@
|
||||||
</trans-unit>
|
</trans-unit>
|
||||||
<trans-unit id="CmdLoggerDescription">
|
<trans-unit id="CmdLoggerDescription">
|
||||||
<source>Specify a logger for test results.
|
<source>Specify a logger for test results.
|
||||||
Example: --logger "trx[;LogFileName=<Defaults to unique file name>]"
|
Examples:
|
||||||
|
Log in trx format using a unqiue file name: --logger trx
|
||||||
|
Log in trx format using the specified file name: --logger "trx;LogFileName=<TestResults.trx>"
|
||||||
More info on logger arguments support:https://aka.ms/vstest-report</source>
|
More info on logger arguments support:https://aka.ms/vstest-report</source>
|
||||||
<target state="translated">Consente di specificare un logger per i risultati dei test.
|
<target state="needs-review-translation">Consente di specificare un logger per i risultati dei test.
|
||||||
Esempio: --logger "trx[;LogFileName=<l'impostazione predefinita è un nome file univoco>]"
|
Esempio: --logger "trx[;LogFileName=<l'impostazione predefinita è un nome file univoco>]"
|
||||||
Per altre informazioni sul supporto degli argomenti del logger, vedere: https://aka.ms/vstest-report</target>
|
Per altre informazioni sul supporto degli argomenti del logger, vedere: https://aka.ms/vstest-report</target>
|
||||||
<note />
|
<note />
|
||||||
|
|
|
@ -73,9 +73,11 @@
|
||||||
</trans-unit>
|
</trans-unit>
|
||||||
<trans-unit id="CmdLoggerDescription">
|
<trans-unit id="CmdLoggerDescription">
|
||||||
<source>Specify a logger for test results.
|
<source>Specify a logger for test results.
|
||||||
Example: --logger "trx[;LogFileName=<Defaults to unique file name>]"
|
Examples:
|
||||||
|
Log in trx format using a unqiue file name: --logger trx
|
||||||
|
Log in trx format using the specified file name: --logger "trx;LogFileName=<TestResults.trx>"
|
||||||
More info on logger arguments support:https://aka.ms/vstest-report</source>
|
More info on logger arguments support:https://aka.ms/vstest-report</source>
|
||||||
<target state="translated">テスト結果のロガーを指定します。
|
<target state="needs-review-translation">テスト結果のロガーを指定します。
|
||||||
例: --logger "trx[;LogFileName=<Defaults to unique file name>]"
|
例: --logger "trx[;LogFileName=<Defaults to unique file name>]"
|
||||||
ロガー引数サポートの詳細:https://aka.ms/vstest-report</target>
|
ロガー引数サポートの詳細:https://aka.ms/vstest-report</target>
|
||||||
<note />
|
<note />
|
||||||
|
|
|
@ -73,9 +73,11 @@
|
||||||
</trans-unit>
|
</trans-unit>
|
||||||
<trans-unit id="CmdLoggerDescription">
|
<trans-unit id="CmdLoggerDescription">
|
||||||
<source>Specify a logger for test results.
|
<source>Specify a logger for test results.
|
||||||
Example: --logger "trx[;LogFileName=<Defaults to unique file name>]"
|
Examples:
|
||||||
|
Log in trx format using a unqiue file name: --logger trx
|
||||||
|
Log in trx format using the specified file name: --logger "trx;LogFileName=<TestResults.trx>"
|
||||||
More info on logger arguments support:https://aka.ms/vstest-report</source>
|
More info on logger arguments support:https://aka.ms/vstest-report</source>
|
||||||
<target state="translated">테스트 결과에 대해 로거를 지정합니다.
|
<target state="needs-review-translation">테스트 결과에 대해 로거를 지정합니다.
|
||||||
예: --logger "trx[;LogFileName=<고유한 파일 이름을 기본값으로 설정>]"
|
예: --logger "trx[;LogFileName=<고유한 파일 이름을 기본값으로 설정>]"
|
||||||
로거 인수 지원에 대한 추가 정보: https://aka.ms/vstest-report</target>
|
로거 인수 지원에 대한 추가 정보: https://aka.ms/vstest-report</target>
|
||||||
<note />
|
<note />
|
||||||
|
|
|
@ -73,9 +73,11 @@
|
||||||
</trans-unit>
|
</trans-unit>
|
||||||
<trans-unit id="CmdLoggerDescription">
|
<trans-unit id="CmdLoggerDescription">
|
||||||
<source>Specify a logger for test results.
|
<source>Specify a logger for test results.
|
||||||
Example: --logger "trx[;LogFileName=<Defaults to unique file name>]"
|
Examples:
|
||||||
|
Log in trx format using a unqiue file name: --logger trx
|
||||||
|
Log in trx format using the specified file name: --logger "trx;LogFileName=<TestResults.trx>"
|
||||||
More info on logger arguments support:https://aka.ms/vstest-report</source>
|
More info on logger arguments support:https://aka.ms/vstest-report</source>
|
||||||
<target state="translated">Określ rejestrator wyników testów.
|
<target state="needs-review-translation">Określ rejestrator wyników testów.
|
||||||
Przykład: --logger "trx[;LogFileName=<domyślnie jest to unikatowa nazwa pliku>]"
|
Przykład: --logger "trx[;LogFileName=<domyślnie jest to unikatowa nazwa pliku>]"
|
||||||
Więcej informacji o obsłudze argumentów rejestratora: https://aka.ms/vstest-report</target>
|
Więcej informacji o obsłudze argumentów rejestratora: https://aka.ms/vstest-report</target>
|
||||||
<note />
|
<note />
|
||||||
|
|
|
@ -73,9 +73,11 @@
|
||||||
</trans-unit>
|
</trans-unit>
|
||||||
<trans-unit id="CmdLoggerDescription">
|
<trans-unit id="CmdLoggerDescription">
|
||||||
<source>Specify a logger for test results.
|
<source>Specify a logger for test results.
|
||||||
Example: --logger "trx[;LogFileName=<Defaults to unique file name>]"
|
Examples:
|
||||||
|
Log in trx format using a unqiue file name: --logger trx
|
||||||
|
Log in trx format using the specified file name: --logger "trx;LogFileName=<TestResults.trx>"
|
||||||
More info on logger arguments support:https://aka.ms/vstest-report</source>
|
More info on logger arguments support:https://aka.ms/vstest-report</source>
|
||||||
<target state="translated">Especifique um agente para os resultados de teste.
|
<target state="needs-review-translation">Especifique um agente para os resultados de teste.
|
||||||
Exemplo: --logger "trx[;LogFileName=<Defaults to unique file name>]"
|
Exemplo: --logger "trx[;LogFileName=<Defaults to unique file name>]"
|
||||||
Mais informações sobre suporte a argumentos de agente: https://aka.ms/vstest-report</target>
|
Mais informações sobre suporte a argumentos de agente: https://aka.ms/vstest-report</target>
|
||||||
<note />
|
<note />
|
||||||
|
|
|
@ -73,9 +73,11 @@
|
||||||
</trans-unit>
|
</trans-unit>
|
||||||
<trans-unit id="CmdLoggerDescription">
|
<trans-unit id="CmdLoggerDescription">
|
||||||
<source>Specify a logger for test results.
|
<source>Specify a logger for test results.
|
||||||
Example: --logger "trx[;LogFileName=<Defaults to unique file name>]"
|
Examples:
|
||||||
|
Log in trx format using a unqiue file name: --logger trx
|
||||||
|
Log in trx format using the specified file name: --logger "trx;LogFileName=<TestResults.trx>"
|
||||||
More info on logger arguments support:https://aka.ms/vstest-report</source>
|
More info on logger arguments support:https://aka.ms/vstest-report</source>
|
||||||
<target state="translated">Укажите средство ведения журнала для результатов теста.
|
<target state="needs-review-translation">Укажите средство ведения журнала для результатов теста.
|
||||||
Пример: --logger "trx[;LogFileName=<по умолчанию используется уникальное имя файла>]"
|
Пример: --logger "trx[;LogFileName=<по умолчанию используется уникальное имя файла>]"
|
||||||
Дополнительные сведения о поддержке аргументов средства ведения журнала: https://aka.ms/vstest-report</target>
|
Дополнительные сведения о поддержке аргументов средства ведения журнала: https://aka.ms/vstest-report</target>
|
||||||
<note />
|
<note />
|
||||||
|
|
|
@ -73,9 +73,11 @@
|
||||||
</trans-unit>
|
</trans-unit>
|
||||||
<trans-unit id="CmdLoggerDescription">
|
<trans-unit id="CmdLoggerDescription">
|
||||||
<source>Specify a logger for test results.
|
<source>Specify a logger for test results.
|
||||||
Example: --logger "trx[;LogFileName=<Defaults to unique file name>]"
|
Examples:
|
||||||
|
Log in trx format using a unqiue file name: --logger trx
|
||||||
|
Log in trx format using the specified file name: --logger "trx;LogFileName=<TestResults.trx>"
|
||||||
More info on logger arguments support:https://aka.ms/vstest-report</source>
|
More info on logger arguments support:https://aka.ms/vstest-report</source>
|
||||||
<target state="translated">Test sonuçları için bir günlükçü belirtin.
|
<target state="needs-review-translation">Test sonuçları için bir günlükçü belirtin.
|
||||||
Örnek: --logger "trx[;LogFileName=<Varsayılan olarak benzersiz dosya adı kullanılır>]"
|
Örnek: --logger "trx[;LogFileName=<Varsayılan olarak benzersiz dosya adı kullanılır>]"
|
||||||
Günlükçü bağımsız değişkenleri desteği hakkında daha fazla bilgi: https://aka.ms/vstest-report</target>
|
Günlükçü bağımsız değişkenleri desteği hakkında daha fazla bilgi: https://aka.ms/vstest-report</target>
|
||||||
<note />
|
<note />
|
||||||
|
|
|
@ -73,9 +73,11 @@
|
||||||
</trans-unit>
|
</trans-unit>
|
||||||
<trans-unit id="CmdLoggerDescription">
|
<trans-unit id="CmdLoggerDescription">
|
||||||
<source>Specify a logger for test results.
|
<source>Specify a logger for test results.
|
||||||
Example: --logger "trx[;LogFileName=<Defaults to unique file name>]"
|
Examples:
|
||||||
|
Log in trx format using a unqiue file name: --logger trx
|
||||||
|
Log in trx format using the specified file name: --logger "trx;LogFileName=<TestResults.trx>"
|
||||||
More info on logger arguments support:https://aka.ms/vstest-report</source>
|
More info on logger arguments support:https://aka.ms/vstest-report</source>
|
||||||
<target state="translated">指定测试结果的记录器。
|
<target state="needs-review-translation">指定测试结果的记录器。
|
||||||
示例: --logger "trx[;LogFileName=<Defaults to unique file name>]"
|
示例: --logger "trx[;LogFileName=<Defaults to unique file name>]"
|
||||||
有关记录器参数的详细信息,请访问 support:https://aka.ms/vstest-report</target>
|
有关记录器参数的详细信息,请访问 support:https://aka.ms/vstest-report</target>
|
||||||
<note />
|
<note />
|
||||||
|
|
|
@ -73,9 +73,11 @@
|
||||||
</trans-unit>
|
</trans-unit>
|
||||||
<trans-unit id="CmdLoggerDescription">
|
<trans-unit id="CmdLoggerDescription">
|
||||||
<source>Specify a logger for test results.
|
<source>Specify a logger for test results.
|
||||||
Example: --logger "trx[;LogFileName=<Defaults to unique file name>]"
|
Examples:
|
||||||
|
Log in trx format using a unqiue file name: --logger trx
|
||||||
|
Log in trx format using the specified file name: --logger "trx;LogFileName=<TestResults.trx>"
|
||||||
More info on logger arguments support:https://aka.ms/vstest-report</source>
|
More info on logger arguments support:https://aka.ms/vstest-report</source>
|
||||||
<target state="translated">指定測試結果的記錄器。
|
<target state="needs-review-translation">指定測試結果的記錄器。
|
||||||
範例: --logger "trx[;LogFileName=<預設為唯一的檔案名稱>]"
|
範例: --logger "trx[;LogFileName=<預設為唯一的檔案名稱>]"
|
||||||
記錄器引數支援的詳細資訊: https://aka.ms/vstest-report</target>
|
記錄器引數支援的詳細資訊: https://aka.ms/vstest-report</target>
|
||||||
<note />
|
<note />
|
||||||
|
|
|
@ -12,7 +12,7 @@ namespace Microsoft.DotNet.Tests.EndToEnd
|
||||||
{
|
{
|
||||||
public class GivenDotNetUsesMSBuild : TestBase
|
public class GivenDotNetUsesMSBuild : TestBase
|
||||||
{
|
{
|
||||||
[Fact(Skip = "https://github.com/dotnet/cli/issues/7476")]
|
[Fact]
|
||||||
public void ItCanNewRestoreBuildRunCleanMSBuildProject()
|
public void ItCanNewRestoreBuildRunCleanMSBuildProject()
|
||||||
{
|
{
|
||||||
using (DisposableDirectory directory = Temp.CreateDirectory())
|
using (DisposableDirectory directory = Temp.CreateDirectory())
|
||||||
|
|
|
@ -85,7 +85,7 @@ namespace Microsoft.DotNet.Cli.Build.Tests
|
||||||
.And.HaveStdOutContaining("project.assets.json");
|
.And.HaveStdOutContaining("project.assets.json");
|
||||||
}
|
}
|
||||||
|
|
||||||
[Fact(Skip = "https://github.com/dotnet/cli/issues/7476")]
|
[Fact]
|
||||||
public void ItRunsWhenRestoringToSpecificPackageDir()
|
public void ItRunsWhenRestoringToSpecificPackageDir()
|
||||||
{
|
{
|
||||||
var rootPath = TestAssets.CreateTestDirectory().FullName;
|
var rootPath = TestAssets.CreateTestDirectory().FullName;
|
||||||
|
|
|
@ -38,6 +38,8 @@ SDK commands:
|
||||||
nuget Provides additional NuGet commands.
|
nuget Provides additional NuGet commands.
|
||||||
msbuild Runs Microsoft Build Engine (MSBuild).
|
msbuild Runs Microsoft Build Engine (MSBuild).
|
||||||
vstest Runs Microsoft Test Execution Command Line Tool.
|
vstest Runs Microsoft Test Execution Command Line Tool.
|
||||||
|
store Stores the specified assemblies in the runtime store.
|
||||||
|
help Show help.
|
||||||
|
|
||||||
Common options:
|
Common options:
|
||||||
-v|--verbosity Set the verbosity level of the command. Allowed values are q[uiet], m[inimal], n[ormal], d[etailed], and diag[nostic].
|
-v|--verbosity Set the verbosity level of the command. Allowed values are q[uiet], m[inimal], n[ormal], d[etailed], and diag[nostic].
|
||||||
|
|
|
@ -44,11 +44,16 @@ namespace Microsoft.DotNet.New.Tests
|
||||||
var rootPath = TestAssets.CreateTestDirectory().FullName;
|
var rootPath = TestAssets.CreateTestDirectory().FullName;
|
||||||
var packagesDirectory = Path.Combine(rootPath, "packages");
|
var packagesDirectory = Path.Combine(rootPath, "packages");
|
||||||
|
|
||||||
|
// For testing the 2.1 templates - some of their packages are currently only in private feeds.
|
||||||
|
var configFile = Path.Combine(rootPath, "..", "..", "..", "..", "..", "NuGet.tempaspnetpatch.config");
|
||||||
|
// For "normal" builds, once the packages needed for 2.1 templates are in the public feeds
|
||||||
|
//var configFile = Path.Combine(RepoDirectoriesProvider.RepoRoot, "NuGet.Config");
|
||||||
|
|
||||||
foreach (string cSharpTemplate in cSharpTemplates)
|
foreach (string cSharpTemplate in cSharpTemplates)
|
||||||
{
|
{
|
||||||
var projectFolder = Path.Combine(rootPath, cSharpTemplate + "1");
|
var projectFolder = Path.Combine(rootPath, cSharpTemplate + "1");
|
||||||
Directory.CreateDirectory(projectFolder);
|
Directory.CreateDirectory(projectFolder);
|
||||||
CreateAndRestoreNewProject(cSharpTemplate, projectFolder, packagesDirectory);
|
CreateAndRestoreNewProject(cSharpTemplate, projectFolder, packagesDirectory, configFile);
|
||||||
}
|
}
|
||||||
|
|
||||||
Directory.EnumerateFiles(packagesDirectory, $"*.nupkg", SearchOption.AllDirectories)
|
Directory.EnumerateFiles(packagesDirectory, $"*.nupkg", SearchOption.AllDirectories)
|
||||||
|
@ -58,25 +63,24 @@ namespace Microsoft.DotNet.New.Tests
|
||||||
private void CreateAndRestoreNewProject(
|
private void CreateAndRestoreNewProject(
|
||||||
string projectType,
|
string projectType,
|
||||||
string projectFolder,
|
string projectFolder,
|
||||||
string packagesDirectory)
|
string packagesDirectory,
|
||||||
|
string configFile)
|
||||||
{
|
{
|
||||||
var repoRootNuGetConfig = Path.Combine(RepoDirectoriesProvider.RepoRoot, "NuGet.Config");
|
|
||||||
|
|
||||||
new NewCommand()
|
new NewCommand()
|
||||||
.WithWorkingDirectory(projectFolder)
|
.WithWorkingDirectory(projectFolder)
|
||||||
.Execute($"{projectType} --debug:ephemeral-hive --no-restore")
|
.Execute($"{projectType} --debug:ephemeral-hive --no-restore")
|
||||||
.Should().Pass();
|
.Should().Pass();
|
||||||
|
|
||||||
// https://github.com/dotnet/templating/issues/946 - remove DisableImplicitAssetTargetFallback once this is fixed.
|
|
||||||
new RestoreCommand()
|
new RestoreCommand()
|
||||||
.WithWorkingDirectory(projectFolder)
|
.WithWorkingDirectory(projectFolder)
|
||||||
.Execute($"--configfile {repoRootNuGetConfig} --packages {packagesDirectory} /p:DisableImplicitAssetTargetFallback=true")
|
.Execute($"--configfile {configFile} --packages {packagesDirectory}")
|
||||||
.Should().Pass();
|
.Should().Pass();
|
||||||
}
|
}
|
||||||
|
|
||||||
[Theory(Skip = "https://github.com/dotnet/cli/issues/7476")]
|
[Theory]
|
||||||
[InlineData("console", "RuntimeFrameworkVersion", "microsoft.netcore.app")]
|
[InlineData("console", "RuntimeFrameworkVersion", "microsoft.netcore.app")]
|
||||||
[InlineData("classlib", "NetStandardImplicitPackageVersion", "netstandard.library")]
|
// re-enable when this bug is resolved: https://github.com/dotnet/cli/issues/7574
|
||||||
|
//[InlineData("classlib", "NetStandardImplicitPackageVersion", "netstandard.library")]
|
||||||
public void NewProjectRestoresCorrectPackageVersion(string type, string propertyName, string packageName)
|
public void NewProjectRestoresCorrectPackageVersion(string type, string propertyName, string packageName)
|
||||||
{
|
{
|
||||||
var rootPath = TestAssets.CreateTestDirectory(identifier: $"_{type}").FullName;
|
var rootPath = TestAssets.CreateTestDirectory(identifier: $"_{type}").FullName;
|
||||||
|
|
|
@ -20,14 +20,14 @@ namespace Microsoft.DotNet.New.Tests
|
||||||
[InlineData("C#", "classlib", false, false)]
|
[InlineData("C#", "classlib", false, false)]
|
||||||
[InlineData("C#", "mstest", false, false)]
|
[InlineData("C#", "mstest", false, false)]
|
||||||
[InlineData("C#", "xunit", false, false)]
|
[InlineData("C#", "xunit", false, false)]
|
||||||
[InlineData("C#", "web", false, false)]
|
[InlineData("C#", "web", true, false)]
|
||||||
[InlineData("C#", "mvc", false, false)]
|
[InlineData("C#", "mvc", true, false)]
|
||||||
[InlineData("C#", "webapi", false, false)]
|
[InlineData("C#", "webapi", true, false)]
|
||||||
[InlineData("C#", "angular", false, true)]
|
[InlineData("C#", "angular", false, true)]
|
||||||
[InlineData("C#", "react", false, true)]
|
[InlineData("C#", "react", false, true)]
|
||||||
[InlineData("C#", "reactredux", false, true)]
|
[InlineData("C#", "reactredux", false, true)]
|
||||||
[InlineData("F#", "console", false, false)]
|
[InlineData("F#", "console", false, false)]
|
||||||
// https://github.com/dotnet/cli/issues/7476
|
// re-enable when this bug is resolved: https://github.com/dotnet/cli/issues/7574
|
||||||
//[InlineData("F#", "classlib", false, false)]
|
//[InlineData("F#", "classlib", false, false)]
|
||||||
[InlineData("F#", "mstest", false, false)]
|
[InlineData("F#", "mstest", false, false)]
|
||||||
[InlineData("F#", "xunit", false, false)]
|
[InlineData("F#", "xunit", false, false)]
|
||||||
|
@ -66,10 +66,9 @@ namespace Microsoft.DotNet.New.Tests
|
||||||
Directory.CreateDirectory(Path.Combine(rootPath, "wwwroot", "dist"));
|
Directory.CreateDirectory(Path.Combine(rootPath, "wwwroot", "dist"));
|
||||||
}
|
}
|
||||||
|
|
||||||
// https://github.com/dotnet/templating/issues/946 - remove DisableImplicitAssetTargetFallback once this is fixed.
|
|
||||||
new TestCommand("dotnet")
|
new TestCommand("dotnet")
|
||||||
.WithWorkingDirectory(rootPath)
|
.WithWorkingDirectory(rootPath)
|
||||||
.Execute($"restore /p:DisableImplicitAssetTargetFallback=true")
|
.Execute($"restore")
|
||||||
.Should().Pass();
|
.Should().Pass();
|
||||||
|
|
||||||
var buildResult = new TestCommand("dotnet")
|
var buildResult = new TestCommand("dotnet")
|
||||||
|
|
|
@ -5,6 +5,7 @@
|
||||||
<clear />
|
<clear />
|
||||||
<add key="api.nuget.org" value="https://api.nuget.org/v3/index.json" />
|
<add key="api.nuget.org" value="https://api.nuget.org/v3/index.json" />
|
||||||
<add key="DotnetCore" value="https://dotnet.myget.org/F/dotnet-core/api/v3/index.json" />
|
<add key="DotnetCore" value="https://dotnet.myget.org/F/dotnet-core/api/v3/index.json" />
|
||||||
|
<add key="aspnetcore-dev" value="https://dotnet.myget.org/F/aspnetcore-dev/api/v3/index.json" />
|
||||||
<add key="aspnet-final" value="https://dotnet.myget.org/F/aspnetcore-2-0-0-preview1-no-timestamp/api/v3/index.json" />
|
<add key="aspnet-final" value="https://dotnet.myget.org/F/aspnetcore-2-0-0-preview1-no-timestamp/api/v3/index.json" />
|
||||||
<add key="aspnet-release" value="https://dotnet.myget.org/F/aspnetcore-release/api/v3/index.json" />
|
<add key="aspnet-release" value="https://dotnet.myget.org/F/aspnetcore-release/api/v3/index.json" />
|
||||||
</packageSources>
|
</packageSources>
|
||||||
|
|
|
@ -197,7 +197,7 @@ namespace Microsoft.DotNet.Cli.Publish.Tests
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
[Fact(Skip = "https://github.com/dotnet/cli/issues/7476")]
|
[Fact]
|
||||||
public void ItPublishesAppWhenRestoringToSpecificPackageDirectory()
|
public void ItPublishesAppWhenRestoringToSpecificPackageDirectory()
|
||||||
{
|
{
|
||||||
var rootPath = TestAssets.CreateTestDirectory().FullName;
|
var rootPath = TestAssets.CreateTestDirectory().FullName;
|
||||||
|
|
|
@ -192,7 +192,7 @@ namespace Microsoft.DotNet.Cli.Run.Tests
|
||||||
.And.HaveStdOutContaining("Hello World!");
|
.And.HaveStdOutContaining("Hello World!");
|
||||||
}
|
}
|
||||||
|
|
||||||
[Fact(Skip = "https://github.com/dotnet/cli/issues/7476")]
|
[Fact]
|
||||||
public void ItRunsAppWhenRestoringToSpecificPackageDirectory()
|
public void ItRunsAppWhenRestoringToSpecificPackageDirectory()
|
||||||
{
|
{
|
||||||
var rootPath = TestAssets.CreateTestDirectory().FullName;
|
var rootPath = TestAssets.CreateTestDirectory().FullName;
|
||||||
|
|
Loading…
Reference in a new issue