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 1
1
version : 2.1.0-alpha.{build}+{branch}
2
2
init :
3
- - git config --global core.autocrlf true
3
+ - git config --global core.autocrlf input
4
4
clone_depth : 1
5
5
branches :
6
6
only :
Original file line number Diff line number Diff line change 3
3
param (
4
4
[ValidateSet (' Debug' , ' Release' )]
5
5
$Configuration = $null ,
6
+ [switch ]
7
+ $IsOfficialBuild ,
6
8
[Parameter (ValueFromRemainingArguments = $true )]
7
9
[string []]$MSBuildArgs
8
10
)
@@ -26,15 +28,19 @@ function exec([string]$_cmd) {
26
28
#
27
29
28
30
if (! $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'
30
36
}
31
37
32
38
$artifacts = " $PSScriptRoot /artifacts/"
33
39
34
40
Remove-Item - Recurse $artifacts - ErrorAction Ignore
35
41
36
42
exec dotnet restore @MSBuildArgs
37
- exec dotnet build -- no- restore -- configuration $Configuration
43
+ exec dotnet build -- no- restore -- configuration $Configuration @MSBuildArgs
38
44
exec dotnet pack -- no- restore -- no- build -- configuration $Configuration - o $artifacts @MSBuildArgs
39
45
exec dotnet test -- no- restore -- no- build -- configuration $Configuration ' -clp:Summary' `
40
46
" $PSScriptRoot /test/CommandLineUtils.Tests/McMaster.Extensions.CommandLineUtils.Tests.csproj" `
Original file line number Diff line number Diff line change 1
1
<Project Sdk =" Microsoft.NET.Sdk" >
2
+
2
3
<PropertyGroup >
3
4
<TargetFrameworks >netstandard2.0;netstandard1.6</TargetFrameworks >
4
5
<TargetFrameworks Condition =" $([MSBuild]::IsOSPlatform(Windows))" >$(TargetFrameworks);net45</TargetFrameworks >
@@ -16,9 +17,11 @@ McMaster.Extensions.CommandLineUtils.ArgumentEscaper
16
17
<IncludeSymbols >true</IncludeSymbols >
17
18
<IncludeSource >true</IncludeSource >
18
19
</PropertyGroup >
20
+
19
21
<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 " />
23
25
</ItemGroup >
26
+
24
27
</Project >
You can’t perform that action at this time.
0 commit comments