Merge branch 'master' into tp-insert-0414
This commit is contained in:
commit
3f82e11a91
39 changed files with 315 additions and 263 deletions
|
@ -226,6 +226,8 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "templates", "templates", "{
|
||||||
EndProject
|
EndProject
|
||||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "dotnet-back-compat.Tests", "test\dotnet-back-compat.Tests\dotnet-back-compat.Tests.csproj", "{A4C198B4-D46E-4CA8-87DF-B2B206DCCAE6}"
|
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "dotnet-back-compat.Tests", "test\dotnet-back-compat.Tests\dotnet-back-compat.Tests.csproj", "{A4C198B4-D46E-4CA8-87DF-B2B206DCCAE6}"
|
||||||
EndProject
|
EndProject
|
||||||
|
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "dotnet-outputsframeworkversion-netcoreapp1.0", "TestAssets\TestPackages\dotnet-outputsframeworkversion\dotnet-outputsframeworkversion-netcoreapp1.0\dotnet-outputsframeworkversion-netcoreapp1.0.csproj", "{3F7D56A3-A280-467E-8916-C18659C243BA}"
|
||||||
|
EndProject
|
||||||
Global
|
Global
|
||||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||||
Debug|Any CPU = Debug|Any CPU
|
Debug|Any CPU = Debug|Any CPU
|
||||||
|
@ -962,6 +964,30 @@ Global
|
||||||
{BBB5A4C8-CD2D-4A6A-9159-0FEAF84B745E}.RelWithDebInfo|x64.Build.0 = Release|Any CPU
|
{BBB5A4C8-CD2D-4A6A-9159-0FEAF84B745E}.RelWithDebInfo|x64.Build.0 = Release|Any CPU
|
||||||
{BBB5A4C8-CD2D-4A6A-9159-0FEAF84B745E}.RelWithDebInfo|x86.ActiveCfg = Release|Any CPU
|
{BBB5A4C8-CD2D-4A6A-9159-0FEAF84B745E}.RelWithDebInfo|x86.ActiveCfg = Release|Any CPU
|
||||||
{BBB5A4C8-CD2D-4A6A-9159-0FEAF84B745E}.RelWithDebInfo|x86.Build.0 = Release|Any CPU
|
{BBB5A4C8-CD2D-4A6A-9159-0FEAF84B745E}.RelWithDebInfo|x86.Build.0 = Release|Any CPU
|
||||||
|
{8AA88E83-6A98-4AD6-86EB-2ED4F6EDA17F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||||
|
{8AA88E83-6A98-4AD6-86EB-2ED4F6EDA17F}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||||
|
{8AA88E83-6A98-4AD6-86EB-2ED4F6EDA17F}.Debug|x64.ActiveCfg = Debug|Any CPU
|
||||||
|
{8AA88E83-6A98-4AD6-86EB-2ED4F6EDA17F}.Debug|x64.Build.0 = Debug|Any CPU
|
||||||
|
{8AA88E83-6A98-4AD6-86EB-2ED4F6EDA17F}.Debug|x86.ActiveCfg = Debug|Any CPU
|
||||||
|
{8AA88E83-6A98-4AD6-86EB-2ED4F6EDA17F}.Debug|x86.Build.0 = Debug|Any CPU
|
||||||
|
{8AA88E83-6A98-4AD6-86EB-2ED4F6EDA17F}.MinSizeRel|Any CPU.ActiveCfg = Debug|Any CPU
|
||||||
|
{8AA88E83-6A98-4AD6-86EB-2ED4F6EDA17F}.MinSizeRel|Any CPU.Build.0 = Debug|Any CPU
|
||||||
|
{8AA88E83-6A98-4AD6-86EB-2ED4F6EDA17F}.MinSizeRel|x64.ActiveCfg = Debug|Any CPU
|
||||||
|
{8AA88E83-6A98-4AD6-86EB-2ED4F6EDA17F}.MinSizeRel|x64.Build.0 = Debug|Any CPU
|
||||||
|
{8AA88E83-6A98-4AD6-86EB-2ED4F6EDA17F}.MinSizeRel|x86.ActiveCfg = Debug|Any CPU
|
||||||
|
{8AA88E83-6A98-4AD6-86EB-2ED4F6EDA17F}.MinSizeRel|x86.Build.0 = Debug|Any CPU
|
||||||
|
{8AA88E83-6A98-4AD6-86EB-2ED4F6EDA17F}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||||
|
{8AA88E83-6A98-4AD6-86EB-2ED4F6EDA17F}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||||
|
{8AA88E83-6A98-4AD6-86EB-2ED4F6EDA17F}.Release|x64.ActiveCfg = Release|Any CPU
|
||||||
|
{8AA88E83-6A98-4AD6-86EB-2ED4F6EDA17F}.Release|x64.Build.0 = Release|Any CPU
|
||||||
|
{8AA88E83-6A98-4AD6-86EB-2ED4F6EDA17F}.Release|x86.ActiveCfg = Release|Any CPU
|
||||||
|
{8AA88E83-6A98-4AD6-86EB-2ED4F6EDA17F}.Release|x86.Build.0 = Release|Any CPU
|
||||||
|
{8AA88E83-6A98-4AD6-86EB-2ED4F6EDA17F}.RelWithDebInfo|Any CPU.ActiveCfg = Release|Any CPU
|
||||||
|
{8AA88E83-6A98-4AD6-86EB-2ED4F6EDA17F}.RelWithDebInfo|Any CPU.Build.0 = Release|Any CPU
|
||||||
|
{8AA88E83-6A98-4AD6-86EB-2ED4F6EDA17F}.RelWithDebInfo|x64.ActiveCfg = Release|Any CPU
|
||||||
|
{8AA88E83-6A98-4AD6-86EB-2ED4F6EDA17F}.RelWithDebInfo|x64.Build.0 = Release|Any CPU
|
||||||
|
{8AA88E83-6A98-4AD6-86EB-2ED4F6EDA17F}.RelWithDebInfo|x86.ActiveCfg = Release|Any CPU
|
||||||
|
{8AA88E83-6A98-4AD6-86EB-2ED4F6EDA17F}.RelWithDebInfo|x86.Build.0 = Release|Any CPU
|
||||||
{726D2CB9-80E5-4496-9C86-910AC452C45E}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
{726D2CB9-80E5-4496-9C86-910AC452C45E}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||||
{726D2CB9-80E5-4496-9C86-910AC452C45E}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
{726D2CB9-80E5-4496-9C86-910AC452C45E}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||||
{726D2CB9-80E5-4496-9C86-910AC452C45E}.Debug|x64.ActiveCfg = Release|Any CPU
|
{726D2CB9-80E5-4496-9C86-910AC452C45E}.Debug|x64.ActiveCfg = Release|Any CPU
|
||||||
|
@ -1538,6 +1564,30 @@ Global
|
||||||
{A4C198B4-D46E-4CA8-87DF-B2B206DCCAE6}.RelWithDebInfo|x64.Build.0 = Release|Any CPU
|
{A4C198B4-D46E-4CA8-87DF-B2B206DCCAE6}.RelWithDebInfo|x64.Build.0 = Release|Any CPU
|
||||||
{A4C198B4-D46E-4CA8-87DF-B2B206DCCAE6}.RelWithDebInfo|x86.ActiveCfg = Release|Any CPU
|
{A4C198B4-D46E-4CA8-87DF-B2B206DCCAE6}.RelWithDebInfo|x86.ActiveCfg = Release|Any CPU
|
||||||
{A4C198B4-D46E-4CA8-87DF-B2B206DCCAE6}.RelWithDebInfo|x86.Build.0 = Release|Any CPU
|
{A4C198B4-D46E-4CA8-87DF-B2B206DCCAE6}.RelWithDebInfo|x86.Build.0 = Release|Any CPU
|
||||||
|
{3F7D56A3-A280-467E-8916-C18659C243BA}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||||
|
{3F7D56A3-A280-467E-8916-C18659C243BA}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||||
|
{3F7D56A3-A280-467E-8916-C18659C243BA}.Debug|x64.ActiveCfg = Debug|Any CPU
|
||||||
|
{3F7D56A3-A280-467E-8916-C18659C243BA}.Debug|x64.Build.0 = Debug|Any CPU
|
||||||
|
{3F7D56A3-A280-467E-8916-C18659C243BA}.Debug|x86.ActiveCfg = Debug|Any CPU
|
||||||
|
{3F7D56A3-A280-467E-8916-C18659C243BA}.Debug|x86.Build.0 = Debug|Any CPU
|
||||||
|
{3F7D56A3-A280-467E-8916-C18659C243BA}.MinSizeRel|Any CPU.ActiveCfg = Debug|Any CPU
|
||||||
|
{3F7D56A3-A280-467E-8916-C18659C243BA}.MinSizeRel|Any CPU.Build.0 = Debug|Any CPU
|
||||||
|
{3F7D56A3-A280-467E-8916-C18659C243BA}.MinSizeRel|x64.ActiveCfg = Debug|Any CPU
|
||||||
|
{3F7D56A3-A280-467E-8916-C18659C243BA}.MinSizeRel|x64.Build.0 = Debug|Any CPU
|
||||||
|
{3F7D56A3-A280-467E-8916-C18659C243BA}.MinSizeRel|x86.ActiveCfg = Debug|Any CPU
|
||||||
|
{3F7D56A3-A280-467E-8916-C18659C243BA}.MinSizeRel|x86.Build.0 = Debug|Any CPU
|
||||||
|
{3F7D56A3-A280-467E-8916-C18659C243BA}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||||
|
{3F7D56A3-A280-467E-8916-C18659C243BA}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||||
|
{3F7D56A3-A280-467E-8916-C18659C243BA}.Release|x64.ActiveCfg = Release|Any CPU
|
||||||
|
{3F7D56A3-A280-467E-8916-C18659C243BA}.Release|x64.Build.0 = Release|Any CPU
|
||||||
|
{3F7D56A3-A280-467E-8916-C18659C243BA}.Release|x86.ActiveCfg = Release|Any CPU
|
||||||
|
{3F7D56A3-A280-467E-8916-C18659C243BA}.Release|x86.Build.0 = Release|Any CPU
|
||||||
|
{3F7D56A3-A280-467E-8916-C18659C243BA}.RelWithDebInfo|Any CPU.ActiveCfg = Release|Any CPU
|
||||||
|
{3F7D56A3-A280-467E-8916-C18659C243BA}.RelWithDebInfo|Any CPU.Build.0 = Release|Any CPU
|
||||||
|
{3F7D56A3-A280-467E-8916-C18659C243BA}.RelWithDebInfo|x64.ActiveCfg = Release|Any CPU
|
||||||
|
{3F7D56A3-A280-467E-8916-C18659C243BA}.RelWithDebInfo|x64.Build.0 = Release|Any CPU
|
||||||
|
{3F7D56A3-A280-467E-8916-C18659C243BA}.RelWithDebInfo|x86.ActiveCfg = Release|Any CPU
|
||||||
|
{3F7D56A3-A280-467E-8916-C18659C243BA}.RelWithDebInfo|x86.Build.0 = Release|Any CPU
|
||||||
EndGlobalSection
|
EndGlobalSection
|
||||||
GlobalSection(SolutionProperties) = preSolution
|
GlobalSection(SolutionProperties) = preSolution
|
||||||
HideSolutionNode = FALSE
|
HideSolutionNode = FALSE
|
||||||
|
@ -1607,5 +1657,6 @@ Global
|
||||||
{3275D006-54C8-4C64-A537-B9941C5D2F0C} = {89905EC4-BC0F-443B-8ADF-691321F10108}
|
{3275D006-54C8-4C64-A537-B9941C5D2F0C} = {89905EC4-BC0F-443B-8ADF-691321F10108}
|
||||||
{DE4D1AEB-871B-4E7C-945A-453F9A490C06} = {89905EC4-BC0F-443B-8ADF-691321F10108}
|
{DE4D1AEB-871B-4E7C-945A-453F9A490C06} = {89905EC4-BC0F-443B-8ADF-691321F10108}
|
||||||
{A4C198B4-D46E-4CA8-87DF-B2B206DCCAE6} = {17735A9D-BFD9-4585-A7CB-3208CA6EA8A7}
|
{A4C198B4-D46E-4CA8-87DF-B2B206DCCAE6} = {17735A9D-BFD9-4585-A7CB-3208CA6EA8A7}
|
||||||
|
{3F7D56A3-A280-467E-8916-C18659C243BA} = {1AB5B24B-B317-4142-A5D1-A6E84F15BA34}
|
||||||
EndGlobalSection
|
EndGlobalSection
|
||||||
EndGlobal
|
EndGlobal
|
||||||
|
|
56
README.md
56
README.md
|
@ -23,7 +23,7 @@ This project has adopted the code of conduct defined by the [Contributor Covenan
|
||||||
Build Status
|
Build Status
|
||||||
------------
|
------------
|
||||||
|
|
||||||
|Ubuntu 14.04 / Linux Mint 17 |Ubuntu 16.04 |Debian 8.2 |Windows x64 |Windows x86 |Mac OS X |CentOS 7.1 / Oracle Linux 7.1 |RHEL 7.2 | Linux x64 |
|
|Ubuntu 14.04 / Linux Mint 17 |Ubuntu 16.04 |Debian 8.2 |Windows x64 |Windows x86 |macOS |CentOS 7.1 / Oracle Linux 7.1 |RHEL 7.2 | Linux x64 |
|
||||||
|:------:|:------:|:------:|:------:|:------:|:------:|:------:|:------:|:------:|
|
|:------:|:------:|:------:|:------:|:------:|:------:|:------:|:------:|:------:|
|
||||||
|[![][ubuntu-14.04-build-badge]][ubuntu-14.04-build]|[![][ubuntu-16.04-build-badge]][ubuntu-16.04-build]|[![][debian-8.2-build-badge]][debian-8.2-build]|[![][win-x64-build-badge]][win-x64-build]|[![][win-x86-build-badge]][win-x86-build]|[![][osx-build-badge]][osx-build]|[![][centos-build-badge]][centos-build]|[![][rhel-build-badge]][rhel-build]|[![][linux-build-badge]][linux-build]|
|
|[![][ubuntu-14.04-build-badge]][ubuntu-14.04-build]|[![][ubuntu-16.04-build-badge]][ubuntu-16.04-build]|[![][debian-8.2-build-badge]][debian-8.2-build]|[![][win-x64-build-badge]][win-x64-build]|[![][win-x86-build-badge]][win-x86-build]|[![][osx-build-badge]][osx-build]|[![][centos-build-badge]][centos-build]|[![][rhel-build-badge]][rhel-build]|[![][linux-build-badge]][linux-build]|
|
||||||
|
|
||||||
|
@ -61,32 +61,6 @@ You can download .NET Core SDK as either an installer (MSI, PKG) or a zip (zip,
|
||||||
|
|
||||||
In order to download just the .NET Core runtime without the SDK, please visit https://github.com/dotnet/core-setup#daily-builds.
|
In order to download just the .NET Core runtime without the SDK, please visit https://github.com/dotnet/core-setup#daily-builds.
|
||||||
|
|
||||||
# Debian daily feed
|
|
||||||
|
|
||||||
Newest SDK binaries for 2.0.0 in debian feed may be delayed due to external issues by up to 24h.
|
|
||||||
|
|
||||||
## Obtaining binaries
|
|
||||||
|
|
||||||
Add debian feed:
|
|
||||||
|
|
||||||
```
|
|
||||||
sudo sh -c 'echo "deb [arch=amd64] http://apt-mo.trafficmanager.net/repos/dotnet/ trusty main" > /etc/apt/sources.list.d/dotnetdev.list'
|
|
||||||
|
|
||||||
sudo apt-key adv --keyserver apt-mo.trafficmanager.net --recv-keys 417A0893
|
|
||||||
|
|
||||||
sudo apt-get update
|
|
||||||
```
|
|
||||||
|
|
||||||
Install:
|
|
||||||
```
|
|
||||||
sudo apt-get install <DebianPackageName>=<Version>
|
|
||||||
```
|
|
||||||
|
|
||||||
To list available packages:
|
|
||||||
```
|
|
||||||
apt-cache search dotnet-sdk | grep 2.0.0
|
|
||||||
```
|
|
||||||
|
|
||||||
> **Note:** please be aware that below installers are the **latest bits**. If you
|
> **Note:** please be aware that below installers are the **latest bits**. If you
|
||||||
> want to install the latest released versions, please check out the [section above](#looking-for-v1-of-the-net-core-tooling).
|
> want to install the latest released versions, please check out the [section above](#looking-for-v1-of-the-net-core-tooling).
|
||||||
|
|
||||||
|
@ -97,7 +71,7 @@ apt-cache search dotnet-sdk | grep 2.0.0
|
||||||
| **Ubuntu 14.04 / Linux Mint 17** | [Installer][ubuntu-14.04-installer] - [Checksum][ubuntu-14.04-installer-checksum]<br>*See Installer Note Below<br>[tar.gz][ubuntu-14.04-targz] - [Checksum][ubuntu-14.04-targz-checksum] |
|
| **Ubuntu 14.04 / Linux Mint 17** | [Installer][ubuntu-14.04-installer] - [Checksum][ubuntu-14.04-installer-checksum]<br>*See Installer Note Below<br>[tar.gz][ubuntu-14.04-targz] - [Checksum][ubuntu-14.04-targz-checksum] |
|
||||||
| **Ubuntu 16.04** | [tar.gz][ubuntu-16.04-targz] - [Checksum][ubuntu-16.04-targz-checksum] |
|
| **Ubuntu 16.04** | [tar.gz][ubuntu-16.04-targz] - [Checksum][ubuntu-16.04-targz-checksum] |
|
||||||
| **Debian 8.2** | [tar.gz][debian-8.2-targz] - [Checksum][debian-8.2-targz-checksum] |
|
| **Debian 8.2** | [tar.gz][debian-8.2-targz] - [Checksum][debian-8.2-targz-checksum] |
|
||||||
| **Mac OS X** | [Installer][osx-installer] - [Checksum][osx-installer-checksum]<br>[tar.gz][osx-targz] - [Checksum][osx-targz-checksum] |
|
| **macOS** | [Installer][osx-installer] - [Checksum][osx-installer-checksum]<br>[tar.gz][osx-targz] - [Checksum][osx-targz-checksum] |
|
||||||
| **CentOS 7.1 / Oracle Linux 7** | [tar.gz][centos-targz] - [Checksum][centos-targz-checksum] |
|
| **CentOS 7.1 / Oracle Linux 7** | [tar.gz][centos-targz] - [Checksum][centos-targz-checksum] |
|
||||||
| **RHEL 7.2** | [tar.gz][rhel-targz] - [Checksum][rhel-targz-checksum] |
|
| **RHEL 7.2** | [tar.gz][rhel-targz] - [Checksum][rhel-targz-checksum] |
|
||||||
| **Linux x64** | [tar.gz][linux-targz] - [Checksum][linux-targz-checksum] |
|
| **Linux x64** | [tar.gz][linux-targz] - [Checksum][linux-targz-checksum] |
|
||||||
|
@ -143,6 +117,32 @@ apt-cache search dotnet-sdk | grep 2.0.0
|
||||||
[linux-targz]: https://dotnetcli.blob.core.windows.net/dotnet/Sdk/master/dotnet-dev-linux-x64.latest.tar.gz
|
[linux-targz]: https://dotnetcli.blob.core.windows.net/dotnet/Sdk/master/dotnet-dev-linux-x64.latest.tar.gz
|
||||||
[linux-targz-checksum]: https://dotnetclichecksums.blob.core.windows.net/dotnet/Sdk/master/dotnet-dev-linux-x64.latest.tar.gz.sha
|
[linux-targz-checksum]: https://dotnetclichecksums.blob.core.windows.net/dotnet/Sdk/master/dotnet-dev-linux-x64.latest.tar.gz.sha
|
||||||
|
|
||||||
|
# Debian daily feed
|
||||||
|
|
||||||
|
Newest SDK binaries for 2.0.0 in debian feed may be delayed due to external issues by up to 24h.
|
||||||
|
|
||||||
|
## Obtaining binaries
|
||||||
|
|
||||||
|
Add debian feed:
|
||||||
|
|
||||||
|
```
|
||||||
|
sudo sh -c 'echo "deb [arch=amd64] http://apt-mo.trafficmanager.net/repos/dotnet/ trusty main" > /etc/apt/sources.list.d/dotnetdev.list'
|
||||||
|
|
||||||
|
sudo apt-key adv --keyserver apt-mo.trafficmanager.net --recv-keys 417A0893
|
||||||
|
|
||||||
|
sudo apt-get update
|
||||||
|
```
|
||||||
|
|
||||||
|
Install:
|
||||||
|
```
|
||||||
|
sudo apt-get install <DebianPackageName>=<Version>
|
||||||
|
```
|
||||||
|
|
||||||
|
To list available packages:
|
||||||
|
```
|
||||||
|
apt-cache search dotnet-sdk | grep 2.0.0
|
||||||
|
```
|
||||||
|
|
||||||
Docker
|
Docker
|
||||||
------
|
------
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,15 @@
|
||||||
|
// 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.
|
||||||
|
|
||||||
|
using System;
|
||||||
|
|
||||||
|
namespace ConsoleApplication
|
||||||
|
{
|
||||||
|
public class Program
|
||||||
|
{
|
||||||
|
public static void Main()
|
||||||
|
{
|
||||||
|
Console.WriteLine("netcoreapp1.0");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,15 @@
|
||||||
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
|
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), testAsset.props))\testAsset.props" />
|
||||||
|
|
||||||
|
<PropertyGroup>
|
||||||
|
<TargetFramework>netcoreapp1.0</TargetFramework>
|
||||||
|
<AssemblyName>dotnet-outputsframeworkversion-netcoreapp1.0</AssemblyName>
|
||||||
|
<OutputType>Exe</OutputType>
|
||||||
|
<RuntimeFrameworkVersion>1.1.1</RuntimeFrameworkVersion>
|
||||||
|
</PropertyGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<BuiltProjectOutputGroupOutput Include="$(ProjectRuntimeConfigFilePath)">
|
||||||
|
<FinalOutputPath>$(ProjectRuntimeConfigFilePath)</FinalOutputPath>
|
||||||
|
</BuiltProjectOutputGroupOutput>
|
||||||
|
</ItemGroup>
|
||||||
|
</Project>
|
|
@ -0,0 +1,12 @@
|
||||||
|
<Project Sdk="Microsoft.NET.Sdk" ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
|
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), testAsset.props))\testAsset.props" />
|
||||||
|
|
||||||
|
<PropertyGroup>
|
||||||
|
<OutputType>Exe</OutputType>
|
||||||
|
<TargetFramework>netcoreapp1.1</TargetFramework>
|
||||||
|
</PropertyGroup>
|
||||||
|
|
||||||
|
<ItemGroup>
|
||||||
|
<DotNetCliToolReference Include="dotnet-outputsframeworkversion-netcoreapp1.0" Version="1.0.0" />
|
||||||
|
</ItemGroup>
|
||||||
|
</Project>
|
|
@ -0,0 +1,6 @@
|
||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<configuration>
|
||||||
|
<packageSources>
|
||||||
|
<add key="test-packages" value="../../../artifacts/testpackages" />
|
||||||
|
</packageSources>
|
||||||
|
</configuration>
|
|
@ -0,0 +1,15 @@
|
||||||
|
// 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.
|
||||||
|
|
||||||
|
using System;
|
||||||
|
|
||||||
|
namespace ConsoleApplication
|
||||||
|
{
|
||||||
|
public class Program
|
||||||
|
{
|
||||||
|
public static void Main(string[] args)
|
||||||
|
{
|
||||||
|
Console.WriteLine("Hello World!");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
|
@ -9,6 +9,10 @@ namespace MSBuildTestApp
|
||||||
{
|
{
|
||||||
public static void Main(string[] args)
|
public static void Main(string[] args)
|
||||||
{
|
{
|
||||||
|
if (args.Length > 0)
|
||||||
|
{
|
||||||
|
Console.WriteLine("echo args:" + string.Join(";", args));
|
||||||
|
}
|
||||||
Console.WriteLine("Hello World!");
|
Console.WriteLine("Hello World!");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,12 +1,12 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<CLI_SharedFrameworkVersion>2.0.0-preview1-001978-00</CLI_SharedFrameworkVersion>
|
<CLI_SharedFrameworkVersion>2.0.0-preview1-002021-00</CLI_SharedFrameworkVersion>
|
||||||
<CLI_MSBuild_Version>15.2.0-preview-000093-02</CLI_MSBuild_Version>
|
<CLI_MSBuild_Version>15.2.0-preview-000093-02</CLI_MSBuild_Version>
|
||||||
<CLI_Roslyn_Version>2.0.0-rc4-61325-08</CLI_Roslyn_Version>
|
<CLI_Roslyn_Version>2.0.0-rc4-61325-08</CLI_Roslyn_Version>
|
||||||
<CLI_NETSDK_Version>2.0.0-alpha-20170413-1</CLI_NETSDK_Version>
|
<CLI_NETSDK_Version>2.0.0-alpha-20170414-1</CLI_NETSDK_Version>
|
||||||
<CLI_NuGet_Version>4.3.0-beta1-2418</CLI_NuGet_Version>
|
<CLI_NuGet_Version>4.3.0-beta1-2418</CLI_NuGet_Version>
|
||||||
<CLI_WEBSDK_Version>1.0.0-rel-20170410-441</CLI_WEBSDK_Version>
|
<CLI_WEBSDK_Version>1.0.0-rel-20170413-451</CLI_WEBSDK_Version>
|
||||||
<CLI_TestPlatform_Version>15.1.0-preview-20170414-04</CLI_TestPlatform_Version>
|
<CLI_TestPlatform_Version>15.1.0-preview-20170414-04</CLI_TestPlatform_Version>
|
||||||
<SharedFrameworkVersion>$(CLI_SharedFrameworkVersion)</SharedFrameworkVersion>
|
<SharedFrameworkVersion>$(CLI_SharedFrameworkVersion)</SharedFrameworkVersion>
|
||||||
<SharedHostVersion>$(CLI_SharedFrameworkVersion)</SharedHostVersion>
|
<SharedHostVersion>$(CLI_SharedFrameworkVersion)</SharedHostVersion>
|
||||||
|
|
|
@ -118,6 +118,15 @@
|
||||||
<VersionSuffix></VersionSuffix>
|
<VersionSuffix></VersionSuffix>
|
||||||
<Clean>True</Clean>
|
<Clean>True</Clean>
|
||||||
</BaseTestPackageProject>
|
</BaseTestPackageProject>
|
||||||
|
<BaseTestPackageProject Include="TestAssets/TestPackages/dotnet-outputsframeworkversion/dotnet-outputsframeworkversion-netcoreapp1.0">
|
||||||
|
<Name>dotnet-outputsframeworkversion-netcoreapp1.0</Name>
|
||||||
|
<ProjectName>dotnet-outputsframeworkversion-netcoreapp1.0.csproj</ProjectName>
|
||||||
|
<IsTool>True</IsTool>
|
||||||
|
<IsApplicable>True</IsApplicable>
|
||||||
|
<VersionPrefix>1.0.0</VersionPrefix>
|
||||||
|
<VersionSuffix></VersionSuffix>
|
||||||
|
<Clean>True</Clean>
|
||||||
|
</BaseTestPackageProject>
|
||||||
<BaseTestPackageProject Include="TestAssets/TestPackages/dotnet-portable">
|
<BaseTestPackageProject Include="TestAssets/TestPackages/dotnet-portable">
|
||||||
<Name>dotnet-portable</Name>
|
<Name>dotnet-portable</Name>
|
||||||
<ProjectName>dotnet-portable.csproj</ProjectName>
|
<ProjectName>dotnet-portable.csproj</ProjectName>
|
||||||
|
|
|
@ -27,7 +27,7 @@
|
||||||
<!-- This dependency was added due to an issue in restore where a lower version of this package coming from nuget.commandline.xplat
|
<!-- This dependency was added due to an issue in restore where a lower version of this package coming from nuget.commandline.xplat
|
||||||
led to an error. This is tracked as NuGet issue : https://github.com/NuGet/Home/issues/4213 -->
|
led to an error. This is tracked as NuGet issue : https://github.com/NuGet/Home/issues/4213 -->
|
||||||
<PackageReference Include="Microsoft.Build.Framework" Version="$(CLI_MSBuild_Version)" />
|
<PackageReference Include="Microsoft.Build.Framework" Version="$(CLI_MSBuild_Version)" />
|
||||||
<PackageReference Include="Microsoft.DotNet.PlatformAbstractions" Version="1.0.3" />
|
<PackageReference Include="Microsoft.DotNet.PlatformAbstractions" Version="$(PlatformAbstractionsVersion)" />
|
||||||
<PackageReference Include="Microsoft.DotNet.VersionTools" Version="$(VersionToolsVersion)" />
|
<PackageReference Include="Microsoft.DotNet.VersionTools" Version="$(VersionToolsVersion)" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
</Project>
|
</Project>
|
||||||
|
|
|
@ -5,10 +5,9 @@
|
||||||
<background file="dotnetbackground.png" mime-type="image/png"/>
|
<background file="dotnetbackground.png" mime-type="image/png"/>
|
||||||
<options customize="never" require-scripts="false" />
|
<options customize="never" require-scripts="false" />
|
||||||
<welcome file="welcome.html" mime-type="text/html" />
|
<welcome file="welcome.html" mime-type="text/html" />
|
||||||
<conclusion file="conclusion.html" mime-type="text/html" />
|
|
||||||
<volume-check>
|
<volume-check>
|
||||||
<allowed-os-version>
|
<allowed-os-version>
|
||||||
<os-version min="10.10" />
|
<os-version min="10.12" />
|
||||||
</allowed-os-version>
|
</allowed-os-version>
|
||||||
</volume-check>
|
</volume-check>
|
||||||
|
|
||||||
|
|
|
@ -1,14 +0,0 @@
|
||||||
|
|
||||||
<!DOCTYPE html>
|
|
||||||
<html lang="en">
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8" />
|
|
||||||
<title styles="color:white">Congratulations! You've successfully installed .NET Core CLI!</title>
|
|
||||||
</head>
|
|
||||||
<body>
|
|
||||||
<div align="center" style="font-family: Helvetica;">
|
|
||||||
<h1>The installation was successful.</h1>
|
|
||||||
<p>.NET Core CLI was successfully installed.</p>
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -1,14 +0,0 @@
|
||||||
|
|
||||||
<!DOCTYPE html>
|
|
||||||
<html lang="en">
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8" />
|
|
||||||
<title styles="color:white">Congratulations! You've successfully installed .NET Core CLI!</title>
|
|
||||||
</head>
|
|
||||||
<body>
|
|
||||||
<div align="center" style="font-family: Helvetica;">
|
|
||||||
<h1>The installation was successful.</h1>
|
|
||||||
<p>.NET Core CLI was successfully installed.</p>
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -1,14 +0,0 @@
|
||||||
|
|
||||||
<!DOCTYPE html>
|
|
||||||
<html lang="en">
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8" />
|
|
||||||
<title styles="color:white">Congratulations! You've successfully installed .NET Core CLI!</title>
|
|
||||||
</head>
|
|
||||||
<body>
|
|
||||||
<div align="center" style="font-family: Helvetica;">
|
|
||||||
<h1>The installation was successful.</h1>
|
|
||||||
<p>.NET Core CLI was successfully installed.</p>
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -1,14 +0,0 @@
|
||||||
|
|
||||||
<!DOCTYPE html>
|
|
||||||
<html lang="en">
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8" />
|
|
||||||
<title styles="color:white">Congratulations! You've successfully installed .NET Core CLI!</title>
|
|
||||||
</head>
|
|
||||||
<body>
|
|
||||||
<div align="center" style="font-family: Helvetica;">
|
|
||||||
<h1>The installation was successful.</h1>
|
|
||||||
<p>.NET Core CLI was successfully installed.</p>
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -1,14 +0,0 @@
|
||||||
|
|
||||||
<!DOCTYPE html>
|
|
||||||
<html lang="en">
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8" />
|
|
||||||
<title styles="color:white">Congratulations! You've successfully installed .NET Core CLI!</title>
|
|
||||||
</head>
|
|
||||||
<body>
|
|
||||||
<div align="center" style="font-family: Helvetica;">
|
|
||||||
<h1>The installation was successful.</h1>
|
|
||||||
<p>.NET Core CLI was successfully installed.</p>
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -1,14 +0,0 @@
|
||||||
|
|
||||||
<!DOCTYPE html>
|
|
||||||
<html lang="en">
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8" />
|
|
||||||
<title styles="color:white">Congratulations! You've successfully installed .NET Core CLI!</title>
|
|
||||||
</head>
|
|
||||||
<body>
|
|
||||||
<div align="center" style="font-family: Helvetica;">
|
|
||||||
<h1>The installation was successful.</h1>
|
|
||||||
<p>.NET Core CLI was successfully installed.</p>
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -1,14 +0,0 @@
|
||||||
|
|
||||||
<!DOCTYPE html>
|
|
||||||
<html lang="en">
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8" />
|
|
||||||
<title styles="color:white">Congratulations! You've successfully installed .NET Core CLI!</title>
|
|
||||||
</head>
|
|
||||||
<body>
|
|
||||||
<div align="center" style="font-family: Helvetica;">
|
|
||||||
<h1>The installation was successful.</h1>
|
|
||||||
<p>.NET Core CLI was successfully installed.</p>
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -1,14 +0,0 @@
|
||||||
|
|
||||||
<!DOCTYPE html>
|
|
||||||
<html lang="en">
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8" />
|
|
||||||
<title styles="color:white">Congratulations! You've successfully installed .NET Core CLI!</title>
|
|
||||||
</head>
|
|
||||||
<body>
|
|
||||||
<div align="center" style="font-family: Helvetica;">
|
|
||||||
<h1>The installation was successful.</h1>
|
|
||||||
<p>.NET Core CLI was successfully installed.</p>
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -1,14 +0,0 @@
|
||||||
|
|
||||||
<!DOCTYPE html>
|
|
||||||
<html lang="en">
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8" />
|
|
||||||
<title styles="color:white">Congratulations! You've successfully installed .NET Core CLI!</title>
|
|
||||||
</head>
|
|
||||||
<body>
|
|
||||||
<div align="center" style="font-family: Helvetica;">
|
|
||||||
<h1>The installation was successful.</h1>
|
|
||||||
<p>.NET Core CLI was successfully installed.</p>
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -1,14 +0,0 @@
|
||||||
|
|
||||||
<!DOCTYPE html>
|
|
||||||
<html lang="en">
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8" />
|
|
||||||
<title styles="color:white">Congratulations! You've successfully installed .NET Core CLI!</title>
|
|
||||||
</head>
|
|
||||||
<body>
|
|
||||||
<div align="center" style="font-family: Helvetica;">
|
|
||||||
<h1>The installation was successful.</h1>
|
|
||||||
<p>.NET Core CLI was successfully installed.</p>
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -1,14 +0,0 @@
|
||||||
|
|
||||||
<!DOCTYPE html>
|
|
||||||
<html lang="en">
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8" />
|
|
||||||
<title styles="color:white">Congratulations! You've successfully installed .NET Core CLI!</title>
|
|
||||||
</head>
|
|
||||||
<body>
|
|
||||||
<div align="center" style="font-family: Helvetica;">
|
|
||||||
<h1>The installation was successful.</h1>
|
|
||||||
<p>.NET Core CLI was successfully installed.</p>
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -1,14 +0,0 @@
|
||||||
|
|
||||||
<!DOCTYPE html>
|
|
||||||
<html lang="en">
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8" />
|
|
||||||
<title styles="color:white">Congratulations! You've successfully installed .NET Core CLI!</title>
|
|
||||||
</head>
|
|
||||||
<body>
|
|
||||||
<div align="center" style="font-family: Helvetica;">
|
|
||||||
<h1>The installation was successful.</h1>
|
|
||||||
<p>.NET Core CLI was successfully installed.</p>
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -1,14 +0,0 @@
|
||||||
|
|
||||||
<!DOCTYPE html>
|
|
||||||
<html lang="en">
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8" />
|
|
||||||
<title styles="color:white">Congratulations! You've successfully installed .NET Core CLI!</title>
|
|
||||||
</head>
|
|
||||||
<body>
|
|
||||||
<div align="center" style="font-family: Helvetica;">
|
|
||||||
<h1>The installation was successful.</h1>
|
|
||||||
<p>.NET Core CLI was successfully installed.</p>
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -1,14 +0,0 @@
|
||||||
|
|
||||||
<!DOCTYPE html>
|
|
||||||
<html lang="en">
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8" />
|
|
||||||
<title styles="color:white">Congratulations! You've successfully installed .NET Core CLI!</title>
|
|
||||||
</head>
|
|
||||||
<body>
|
|
||||||
<div align="center" style="font-family: Helvetica;">
|
|
||||||
<h1>The installation was successful.</h1>
|
|
||||||
<p>.NET Core CLI was successfully installed.</p>
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
|
@ -1,4 +1,4 @@
|
||||||
using System;
|
using System;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using Microsoft.DotNet.Cli.CommandLine;
|
using Microsoft.DotNet.Cli.CommandLine;
|
||||||
using Microsoft.DotNet.Cli.Utils;
|
using Microsoft.DotNet.Cli.Utils;
|
||||||
|
@ -24,6 +24,12 @@ namespace Microsoft.DotNet.Cli
|
||||||
|
|
||||||
Console.WriteLine(result.Diagram());
|
Console.WriteLine(result.Diagram());
|
||||||
|
|
||||||
|
if (result.UnparsedTokens.Any())
|
||||||
|
{
|
||||||
|
Console.WriteLine("Unparsed Tokens: ");
|
||||||
|
Console.WriteLine(string.Join(" ", result.UnparsedTokens));
|
||||||
|
}
|
||||||
|
|
||||||
var optionValuesToBeForwarded = result.AppliedCommand()
|
var optionValuesToBeForwarded = result.AppliedCommand()
|
||||||
.OptionValuesToBeForwarded();
|
.OptionValuesToBeForwarded();
|
||||||
if (optionValuesToBeForwarded.Any())
|
if (optionValuesToBeForwarded.Any())
|
||||||
|
|
|
@ -6,7 +6,10 @@ using System.Collections.Generic;
|
||||||
using System.Globalization;
|
using System.Globalization;
|
||||||
using System.IO;
|
using System.IO;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
|
using Microsoft.DotNet.Cli;
|
||||||
using Microsoft.DotNet.Cli.Utils;
|
using Microsoft.DotNet.Cli.Utils;
|
||||||
|
using Microsoft.DotNet.Configurer;
|
||||||
|
using Microsoft.DotNet.Tools.MSBuild;
|
||||||
using Microsoft.TemplateEngine.Abstractions;
|
using Microsoft.TemplateEngine.Abstractions;
|
||||||
using Microsoft.TemplateEngine.Cli;
|
using Microsoft.TemplateEngine.Cli;
|
||||||
using Microsoft.TemplateEngine.Edge;
|
using Microsoft.TemplateEngine.Edge;
|
||||||
|
@ -24,7 +27,16 @@ namespace Microsoft.DotNet.Tools.New
|
||||||
|
|
||||||
public static int Run(string[] args)
|
public static int Run(string[] args)
|
||||||
{
|
{
|
||||||
return New3Command.Run(CommandName, CreateHost(), new TelemetryLogger(null), FirstRun, args);
|
var sessionId = Environment.GetEnvironmentVariable(MSBuildForwardingApp.TelemetrySessionIdEnvironmentVariableName);
|
||||||
|
var telemetry = new Telemetry(new NuGetCacheSentinel(new CliFallbackFolderPathCalculator()), sessionId);
|
||||||
|
var logger = new TelemetryLogger((name, props, measures) =>
|
||||||
|
{
|
||||||
|
if (telemetry.Enabled)
|
||||||
|
{
|
||||||
|
telemetry.TrackEvent(name, props, measures);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
return New3Command.Run(CommandName, CreateHost(), logger, FirstRun, args);
|
||||||
}
|
}
|
||||||
|
|
||||||
private static ITemplateEngineHost CreateHost()
|
private static ITemplateEngineHost CreateHost()
|
||||||
|
|
|
@ -15,9 +15,9 @@ namespace Microsoft.DotNet.Tools.Publish
|
||||||
|
|
||||||
public const string OutputOptionDescription = "Output directory in which to place the published artifacts.";
|
public const string OutputOptionDescription = "Output directory in which to place the published artifacts.";
|
||||||
|
|
||||||
public const string TargetOption = "target.xml";
|
public const string ManifestOption = "manifest.xml";
|
||||||
|
|
||||||
public const string TargetOptionDescription = "The path to a target manifest file that contains the list of packages to be excluded from the publish step.";
|
public const string ManifestOptionDescription = "The path to a target manifest file that contains the list of packages to be excluded from the publish step.";
|
||||||
|
|
||||||
public const string SelfContainedOptionDescription = "Publish the .NET Core runtime with your application so the runtime doesn't need to be installed on the target machine. Defaults to 'true' if a runtime identifier is specified.";
|
public const string SelfContainedOptionDescription = "Publish the .NET Core runtime with your application so the runtime doesn't need to be installed on the target machine. Defaults to 'true' if a runtime identifier is specified.";
|
||||||
}
|
}
|
||||||
|
|
|
@ -26,10 +26,10 @@ namespace Microsoft.DotNet.Cli
|
||||||
CommonOptions.ConfigurationOption(),
|
CommonOptions.ConfigurationOption(),
|
||||||
CommonOptions.VersionSuffixOption(),
|
CommonOptions.VersionSuffixOption(),
|
||||||
Create.Option(
|
Create.Option(
|
||||||
"--target",
|
"--manifest",
|
||||||
LocalizableStrings.TargetOptionDescription,
|
LocalizableStrings.ManifestOptionDescription,
|
||||||
Accept.OneOrMoreArguments()
|
Accept.OneOrMoreArguments()
|
||||||
.With(name: LocalizableStrings.TargetOption)
|
.With(name: LocalizableStrings.ManifestOption)
|
||||||
.ForwardAsSingle(o => $"/p:TargetManifestFiles={string.Join("%3B", o.Arguments)}")),
|
.ForwardAsSingle(o => $"/p:TargetManifestFiles={string.Join("%3B", o.Arguments)}")),
|
||||||
Create.Option(
|
Create.Option(
|
||||||
"--self-contained",
|
"--self-contained",
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
// Copyright (c) .NET Foundation and contributors. All rights reserved.
|
// 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.
|
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
|
||||||
|
|
||||||
using System;
|
using System.Collections.Generic;
|
||||||
using Microsoft.DotNet.Cli.CommandLine;
|
using System.Linq;
|
||||||
using Microsoft.DotNet.Cli.Utils;
|
using Microsoft.DotNet.Cli.Utils;
|
||||||
using Microsoft.DotNet.Cli;
|
using Microsoft.DotNet.Cli;
|
||||||
using Parser = Microsoft.DotNet.Cli.Parser;
|
using Parser = Microsoft.DotNet.Cli.Parser;
|
||||||
|
@ -13,13 +13,22 @@ namespace Microsoft.DotNet.Tools.Run
|
||||||
{
|
{
|
||||||
public static RunCommand FromArgs(string[] args, string msbuildPath = null)
|
public static RunCommand FromArgs(string[] args, string msbuildPath = null)
|
||||||
{
|
{
|
||||||
var parser = Parser.Instance;
|
var result = Parser.Instance.ParseFrom("dotnet run", args);
|
||||||
|
|
||||||
var result = parser.ParseFrom("dotnet run", args);
|
|
||||||
|
|
||||||
result.ShowHelpOrErrorIfAppropriate();
|
result.ShowHelpOrErrorIfAppropriate();
|
||||||
|
|
||||||
return result["dotnet"]["run"].Value<RunCommand>();
|
var runCommand = result["dotnet"]["run"].Value<RunCommand>();
|
||||||
|
return IncludingArgumentsAfterDoubleDash(runCommand, result.UnparsedTokens);
|
||||||
|
}
|
||||||
|
|
||||||
|
private static RunCommand IncludingArgumentsAfterDoubleDash(
|
||||||
|
RunCommand runCommand,
|
||||||
|
IEnumerable<string> unparsedTokens)
|
||||||
|
{
|
||||||
|
return runCommand.MakeNewWithReplaced(
|
||||||
|
args: runCommand.Args
|
||||||
|
.Concat(unparsedTokens)
|
||||||
|
.ToList());
|
||||||
}
|
}
|
||||||
|
|
||||||
public static int Run(string[] args)
|
public static int Run(string[] args)
|
||||||
|
|
|
@ -13,11 +13,11 @@ namespace Microsoft.DotNet.Tools.Run
|
||||||
{
|
{
|
||||||
public partial class RunCommand
|
public partial class RunCommand
|
||||||
{
|
{
|
||||||
public string Configuration { get; set; }
|
public string Configuration { get; private set; }
|
||||||
public string Framework { get; set; }
|
public string Framework { get; private set; }
|
||||||
public bool NoBuild { get; set; }
|
public bool NoBuild { get; private set; }
|
||||||
public string Project { get; set; }
|
public string Project { get; private set; }
|
||||||
public IReadOnlyCollection<string> Args { get; set; }
|
public IReadOnlyCollection<string> Args { get; private set; }
|
||||||
|
|
||||||
private List<string> _args;
|
private List<string> _args;
|
||||||
private bool ShouldBuild => !NoBuild;
|
private bool ShouldBuild => !NoBuild;
|
||||||
|
@ -38,6 +38,34 @@ namespace Microsoft.DotNet.Tools.Run
|
||||||
.ExitCode;
|
.ExitCode;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public RunCommand(string configuration,
|
||||||
|
string framework,
|
||||||
|
bool noBuild,
|
||||||
|
string project,
|
||||||
|
IReadOnlyCollection<string> args)
|
||||||
|
{
|
||||||
|
Configuration = configuration;
|
||||||
|
Framework = framework;
|
||||||
|
NoBuild = noBuild;
|
||||||
|
Project = project;
|
||||||
|
Args = args;
|
||||||
|
}
|
||||||
|
|
||||||
|
public RunCommand MakeNewWithReplaced(string configuration = null,
|
||||||
|
string framework = null,
|
||||||
|
bool? noBuild = null,
|
||||||
|
string project = null,
|
||||||
|
IReadOnlyCollection<string> args = null)
|
||||||
|
{
|
||||||
|
return new RunCommand(
|
||||||
|
configuration ?? this.Configuration,
|
||||||
|
framework ?? this.Framework,
|
||||||
|
noBuild ?? this.NoBuild,
|
||||||
|
project ?? this.Project,
|
||||||
|
args ?? this.Args
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
private void EnsureProjectIsBuilt()
|
private void EnsureProjectIsBuilt()
|
||||||
{
|
{
|
||||||
List<string> buildArgs = new List<string>();
|
List<string> buildArgs = new List<string>();
|
||||||
|
|
|
@ -16,13 +16,13 @@ namespace Microsoft.DotNet.Cli
|
||||||
treatUnmatchedTokensAsErrors: false,
|
treatUnmatchedTokensAsErrors: false,
|
||||||
arguments: Accept.ZeroOrMoreArguments()
|
arguments: Accept.ZeroOrMoreArguments()
|
||||||
.MaterializeAs(o => new RunCommand
|
.MaterializeAs(o => new RunCommand
|
||||||
{
|
(
|
||||||
Configuration = o.SingleArgumentOrDefault("--configuration"),
|
configuration: o.SingleArgumentOrDefault("--configuration"),
|
||||||
Framework = o.SingleArgumentOrDefault("--framework"),
|
framework: o.SingleArgumentOrDefault("--framework"),
|
||||||
NoBuild = o.HasOption("--no-build"),
|
noBuild: o.HasOption("--no-build"),
|
||||||
Project = o.SingleArgumentOrDefault("--project"),
|
project: o.SingleArgumentOrDefault("--project"),
|
||||||
Args = o.Arguments
|
args: o.Arguments
|
||||||
}),
|
)),
|
||||||
options: new[]
|
options: new[]
|
||||||
{
|
{
|
||||||
CommonOptions.HelpOption(),
|
CommonOptions.HelpOption(),
|
||||||
|
|
|
@ -38,9 +38,9 @@ namespace Microsoft.DotNet.Tools.Test.Utilities
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
public PublishCommand WithTargetManifest(string target)
|
public PublishCommand WithTargetManifest(string manifest)
|
||||||
{
|
{
|
||||||
_targetManifests.Add( $"--target {target}");
|
_targetManifests.Add( $"--manifest {manifest}");
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -78,6 +78,24 @@ namespace Microsoft.DotNet.Cli.Build.Tests
|
||||||
.Should().Pass();
|
.Should().Pass();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
[RequiresSpecificFrameworkFact("netcoreapp1.0")] // https://github.com/dotnet/cli/issues/6087
|
||||||
|
public void ItRunsABackwardsVersionedTool()
|
||||||
|
{
|
||||||
|
var testInstance = TestAssets.Get("11TestAppWith10CLIToolReferences")
|
||||||
|
.CreateInstance()
|
||||||
|
.WithSourceFiles()
|
||||||
|
.WithRestoreFiles();
|
||||||
|
|
||||||
|
var testProjectDirectory = testInstance.Root;
|
||||||
|
|
||||||
|
new DotnetCommand(DotnetUnderTest.WithBackwardsCompatibleRuntimes)
|
||||||
|
.WithWorkingDirectory(testInstance.Root)
|
||||||
|
.ExecuteWithCapturedOutput("outputsframeworkversion-netcoreapp1.0")
|
||||||
|
.Should()
|
||||||
|
.Pass()
|
||||||
|
.And
|
||||||
|
.HaveStdOutContaining("netcoreapp1.0");
|
||||||
|
}
|
||||||
|
|
||||||
void ChangeProjectTargetFramework(FileInfo projectFile, string target)
|
void ChangeProjectTargetFramework(FileInfo projectFile, string target)
|
||||||
{
|
{
|
||||||
|
|
|
@ -33,7 +33,7 @@ namespace Microsoft.DotNet.Cli.MSBuild.Tests
|
||||||
[InlineData(new string[] { "-c", "<config>" }, "/p:Configuration=<config>")]
|
[InlineData(new string[] { "-c", "<config>" }, "/p:Configuration=<config>")]
|
||||||
[InlineData(new string[] { "--configuration", "<config>" }, "/p:Configuration=<config>")]
|
[InlineData(new string[] { "--configuration", "<config>" }, "/p:Configuration=<config>")]
|
||||||
[InlineData(new string[] { "--version-suffix", "<versionsuffix>" }, "/p:VersionSuffix=<versionsuffix>")]
|
[InlineData(new string[] { "--version-suffix", "<versionsuffix>" }, "/p:VersionSuffix=<versionsuffix>")]
|
||||||
[InlineData(new string[] { "--target", "<targetfiles>" }, "/p:TargetManifestFiles=<targetfiles>")]
|
[InlineData(new string[] { "--manifest", "<manifestfiles>" }, "/p:TargetManifestFiles=<manifestfiles>")]
|
||||||
[InlineData(new string[] { "-v", "minimal" }, "/verbosity:minimal")]
|
[InlineData(new string[] { "-v", "minimal" }, "/verbosity:minimal")]
|
||||||
[InlineData(new string[] { "--verbosity", "minimal" }, "/verbosity:minimal")]
|
[InlineData(new string[] { "--verbosity", "minimal" }, "/verbosity:minimal")]
|
||||||
[InlineData(new string[] { "<project>" }, "<project>")]
|
[InlineData(new string[] { "<project>" }, "<project>")]
|
||||||
|
@ -60,7 +60,7 @@ namespace Microsoft.DotNet.Cli.MSBuild.Tests
|
||||||
[InlineData(new string[] { "-c", "<config>" }, "/p:Configuration=<config>")]
|
[InlineData(new string[] { "-c", "<config>" }, "/p:Configuration=<config>")]
|
||||||
[InlineData(new string[] { "--configuration", "<config>" }, "/p:Configuration=<config>")]
|
[InlineData(new string[] { "--configuration", "<config>" }, "/p:Configuration=<config>")]
|
||||||
[InlineData(new string[] { "--version-suffix", "<versionsuffix>" }, "/p:VersionSuffix=<versionsuffix>")]
|
[InlineData(new string[] { "--version-suffix", "<versionsuffix>" }, "/p:VersionSuffix=<versionsuffix>")]
|
||||||
[InlineData(new string[] { "--target", "<targetfiles>" }, "/p:TargetManifestFiles=<targetfiles>")]
|
[InlineData(new string[] { "--manifest", "<manifestfiles>" }, "/p:TargetManifestFiles=<manifestfiles>")]
|
||||||
[InlineData(new string[] { "-v", "minimal" }, "/verbosity:minimal")]
|
[InlineData(new string[] { "-v", "minimal" }, "/verbosity:minimal")]
|
||||||
[InlineData(new string[] { "--verbosity", "minimal" }, "/verbosity:minimal")]
|
[InlineData(new string[] { "--verbosity", "minimal" }, "/verbosity:minimal")]
|
||||||
public void OptionForwardingIsCorrect(string[] args, string expectedAdditionalArgs)
|
public void OptionForwardingIsCorrect(string[] args, string expectedAdditionalArgs)
|
||||||
|
|
|
@ -181,5 +181,24 @@ namespace Microsoft.DotNet.Cli.Run.Tests
|
||||||
.Should().Fail()
|
.Should().Fail()
|
||||||
.And.HaveStdErrContaining("--framework");
|
.And.HaveStdErrContaining("--framework");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
[Fact]
|
||||||
|
public void ItCanPassArgumentsToSubjectAppByDoubleDash()
|
||||||
|
{
|
||||||
|
const string testAppName = "MSBuildTestApp";
|
||||||
|
var testInstance = TestAssets.Get(testAppName)
|
||||||
|
.CreateInstance()
|
||||||
|
.WithSourceFiles()
|
||||||
|
.WithRestoreFiles();
|
||||||
|
|
||||||
|
var testProjectDirectory = testInstance.Root.FullName;
|
||||||
|
|
||||||
|
new RunCommand()
|
||||||
|
.WithWorkingDirectory(testProjectDirectory)
|
||||||
|
.ExecuteWithCapturedOutput("-- foo bar baz")
|
||||||
|
.Should()
|
||||||
|
.Pass()
|
||||||
|
.And.HaveStdOutContaining("echo args:foo;bar;baz");
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -72,6 +72,7 @@ namespace Microsoft.DotNet.Cli.Publish.Tests
|
||||||
{
|
{
|
||||||
var testAppName = "NewtonSoftDependentProject";
|
var testAppName = "NewtonSoftDependentProject";
|
||||||
var profileProjectName = "NewtonsoftProfile";
|
var profileProjectName = "NewtonsoftProfile";
|
||||||
|
var targetManifestFileName = "NewtonsoftFilterProfile.xml";
|
||||||
|
|
||||||
var testInstance = TestAssets.Get(testAppName)
|
var testInstance = TestAssets.Get(testAppName)
|
||||||
.CreateInstance()
|
.CreateInstance()
|
||||||
|
@ -80,7 +81,7 @@ namespace Microsoft.DotNet.Cli.Publish.Tests
|
||||||
|
|
||||||
var testProjectDirectory = testInstance.Root.ToString();
|
var testProjectDirectory = testInstance.Root.ToString();
|
||||||
var profileProjectPath = TestAssets.Get(profileProjectName).Root.FullName;
|
var profileProjectPath = TestAssets.Get(profileProjectName).Root.FullName;
|
||||||
var profileFilter = Path.Combine(profileProjectPath, "NewtonsoftFilterProfile.xml");
|
var profileFilter = Path.Combine(profileProjectPath, targetManifestFileName);
|
||||||
|
|
||||||
new RestoreCommand()
|
new RestoreCommand()
|
||||||
.WithWorkingDirectory(testProjectDirectory)
|
.WithWorkingDirectory(testProjectDirectory)
|
||||||
|
@ -101,7 +102,7 @@ namespace Microsoft.DotNet.Cli.Publish.Tests
|
||||||
new DotnetCommand()
|
new DotnetCommand()
|
||||||
.ExecuteWithCapturedOutput(outputDll)
|
.ExecuteWithCapturedOutput(outputDll)
|
||||||
.Should().Fail()
|
.Should().Fail()
|
||||||
.And.HaveStdErrContaining("assembly specified in the dependencies manifest was not found -- package: 'Newtonsoft.Json',");
|
.And.HaveStdErrContaining($"Error: assembly specified in the dependencies manifest was not found probably due to missing runtime store associated with {targetManifestFileName} -- package: 'Newtonsoft.Json',");
|
||||||
}
|
}
|
||||||
|
|
||||||
[Fact]
|
[Fact]
|
||||||
|
|
29
test/dotnet.Tests/ParserTests/RunParserTests.cs
Normal file
29
test/dotnet.Tests/ParserTests/RunParserTests.cs
Normal file
|
@ -0,0 +1,29 @@
|
||||||
|
// 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.
|
||||||
|
|
||||||
|
using System.Linq;
|
||||||
|
using FluentAssertions;
|
||||||
|
using Microsoft.DotNet.Tools.Run;
|
||||||
|
using Xunit;
|
||||||
|
using Xunit.Abstractions;
|
||||||
|
using System;
|
||||||
|
|
||||||
|
namespace Microsoft.DotNet.Tests.ParserTests
|
||||||
|
{
|
||||||
|
public class RunParserTests
|
||||||
|
{
|
||||||
|
public RunParserTests(ITestOutputHelper output)
|
||||||
|
{
|
||||||
|
this.output = output;
|
||||||
|
}
|
||||||
|
|
||||||
|
private readonly ITestOutputHelper output;
|
||||||
|
|
||||||
|
[Fact]
|
||||||
|
public void RunParserCanGetArguementFromDoubleDash()
|
||||||
|
{
|
||||||
|
var runCommand = RunCommand.FromArgs(new[]{ "--", "foo" });
|
||||||
|
runCommand.Args.Single().Should().Be("foo");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
Loading…
Add table
Add a link
Reference in a new issue