File tree Expand file tree Collapse file tree 3 files changed +15
-6
lines changed
Expand file tree Collapse file tree 3 files changed +15
-6
lines changed Original file line number Diff line number Diff line change 11version : 2.1.0-alpha.{build}+{branch}
22init :
3- - git config --global core.autocrlf true
3+ - git config --global core.autocrlf input
44clone_depth : 1
55branches :
66 only :
Original file line number Diff line number Diff line change 33param (
44 [ValidateSet (' Debug' , ' Release' )]
55 $Configuration = $null ,
6+ [switch ]
7+ $IsOfficialBuild ,
68 [Parameter (ValueFromRemainingArguments = $true )]
79 [string []]$MSBuildArgs
810)
@@ -26,15 +28,19 @@ function exec([string]$_cmd) {
2628#
2729
2830if (! $Configuration ) {
29- $Configuration = if ($env: CI ) { ' Release' } else { ' Debug' }
31+ $Configuration = if ($env: CI -or $IsOfficialBuild ) { ' Release' } else { ' Debug' }
32+ }
33+
34+ if ($IsOfficialBuild ) {
35+ $MSBuildArgs += ' -p:CI=true'
3036}
3137
3238$artifacts = " $PSScriptRoot /artifacts/"
3339
3440Remove-Item - Recurse $artifacts - ErrorAction Ignore
3541
3642exec dotnet restore @MSBuildArgs
37- exec dotnet build -- no- restore -- configuration $Configuration
43+ exec dotnet build -- no- restore -- configuration $Configuration @MSBuildArgs
3844exec dotnet pack -- no- restore -- no- build -- configuration $Configuration - o $artifacts @MSBuildArgs
3945exec dotnet test -- no- restore -- no- build -- configuration $Configuration ' -clp:Summary' `
4046 " $PSScriptRoot /test/CommandLineUtils.Tests/McMaster.Extensions.CommandLineUtils.Tests.csproj" `
Original file line number Diff line number Diff line change 11<Project Sdk =" Microsoft.NET.Sdk" >
2+
23 <PropertyGroup >
34 <TargetFrameworks >netstandard2.0;netstandard1.6</TargetFrameworks >
45 <TargetFrameworks Condition =" $([MSBuild]::IsOSPlatform(Windows))" >$(TargetFrameworks);net45</TargetFrameworks >
@@ -16,9 +17,11 @@ McMaster.Extensions.CommandLineUtils.ArgumentEscaper
1617 <IncludeSymbols >true</IncludeSymbols >
1718 <IncludeSource >true</IncludeSource >
1819 </PropertyGroup >
20+
1921 <ItemGroup Condition =" '$(TargetFramework)'=='netstandard1.6'" >
20- <PackageReference Include =" System.AppContext " Version =" 4.3 .0" />
21- <PackageReference Include =" System.Diagnostics.Process " Version =" 4.3 .0" />
22- <PackageReference Include = " System.Threading.Thread " Version = " 4.3.0 " />
22+ <PackageReference Include =" System.Diagnostics.Process " Version =" 4.1 .0" />
23+ <PackageReference Include =" System.Threading.Thread " Version =" 4.0 .0" />
24+ <PackageReference Update = " NETStandard.Library " PrivateAssets = " All " />
2325 </ItemGroup >
26+
2427</Project >
You can’t perform that action at this time.
0 commit comments