File tree Expand file tree Collapse file tree 7 files changed +36
-7
lines changed
test/CommandLineUtils.Tests Expand file tree Collapse file tree 7 files changed +36
-7
lines changed Original file line number Diff line number Diff line change 1- version : 2.0.0-alpha-build {build}
1+ version : 2.0.0-alpha. {build}+{branch }
22init :
33 - git config --global core.autocrlf true
44clone_depth : 1
Original file line number Diff line number Diff line change 11<Project >
22
33 <PropertyGroup >
4+ <Authors >Microsoft;Nate McMaster</Authors >
45 <Product >CommandLineUtils</Product >
5- <RepositoryUrl >https://github.com/natemcmaster/CommandLineUtils</RepositoryUrl >
6+ <Copyright >Copyright © Nate McMaster</Copyright >
7+ <NeutralLanguage >en-US</NeutralLanguage >
8+ <PackageRequireLicenseAcceptance >false</PackageRequireLicenseAcceptance >
9+ <PackageProjectUrl >https://github.com/natemcmaster/CommandLineUtils</PackageProjectUrl >
10+ <RepositoryUrl >https://github.com/natemcmaster/CommandLineUtils.git</RepositoryUrl >
611 <RepositoryType >git</RepositoryType >
12+ <IsPackable >false</IsPackable >
13+ <MinClientVersion >4.3.0</MinClientVersion >
14+ <NoPackageAnalysis >true</NoPackageAnalysis >
715
816 <AssemblyOriginatorKeyFile >$(MSBuildThisFileDirectory)build\StrongName.snk</AssemblyOriginatorKeyFile >
917 <SignAssembly >true</SignAssembly >
1422 <VersionPrefix >2.0.0</VersionPrefix >
1523 <VersionSuffix >alpha</VersionSuffix >
1624 <BuildNumber Condition =" '$(BuildNumber)' == '' " >$(APPVEYOR_BUILD_NUMBER)</BuildNumber >
25+ <BuildNumber Condition =" '$(BuildNumber)' == '' " >0</BuildNumber >
1726 <BranchName Condition =" '$(BranchName)' == '' " >$(APPVEYOR_REPO_BRANCH)</BranchName >
18- <VersionSuffix Condition =" '$(VersionSuffix)' != '' AND '$(BuildNumber)' != '' " >$(VersionSuffix)- $(BuildNumber)</VersionSuffix >
27+ <VersionSuffix Condition =" '$(VersionSuffix)' != '' " >$(VersionSuffix). $(BuildNumber)</VersionSuffix >
1928 <VersionSuffix Condition =" '$(VersionSuffix)' != '' AND '$(BranchName)' != '' " >$(VersionSuffix)+$(BranchName)</VersionSuffix >
2029 </PropertyGroup >
2130
Original file line number Diff line number Diff line change 11<Project >
2+
3+ <Target Name =" UpdateBuildDetails" BeforeTargets =" Pack" Condition =" '$(APPVEYOR)' == 'true'" >
4+ <Exec Command =" appveyor UpdateBuild -Version $(PackageVersion)"
5+ IgnoreExitCode =" true"
6+ IgnoreStandardErrorWarningFormat =" true" />
7+ </Target >
8+
29</Project >
Original file line number Diff line number Diff line change 1+ # !/usr/bin/env powershell
12param (
23 [ValidateSet (' Debug' , ' Release' )]
34 $Configuration = $null
@@ -7,13 +8,20 @@ Set-StrictMode -Version 1
78$ErrorActionPreference = ' Stop'
89
910function exec ([string ]$_cmd ) {
10- Write-Host - ForegroundColor DarkGray " >>> $_cmd $args "
11+ write-host - ForegroundColor DarkGray " >>> $_cmd $args "
12+ $ErrorActionPreference = ' Continue'
1113 & $_cmd @args
14+ $ErrorActionPreference = ' Stop'
1215 if ($LASTEXITCODE -ne 0 ) {
13- Write-Error " Command exited with code $LASTEXITCODE "
16+ write-error " Failed with exit code $LASTEXITCODE "
17+ exit 1
1418 }
1519}
1620
21+ #
22+ # Main
23+ #
24+
1725if (! $Configuration ) {
1826 $Configuration = if ($env: CI ) { ' Release' } else { ' Debug' }
1927}
@@ -22,6 +30,6 @@ $artifacts = "$PSScriptRoot/artifacts/"
2230
2331Remove-Item - Recurse $artifacts - ErrorAction Ignore
2432
25- exec dotnet restore / p:BuildNumber = t000
33+ exec dotnet restore
2634exec dotnet pack - c $Configuration - o $artifacts
2735exec dotnet test - c $Configuration " $PSScriptRoot /test/CommandLineUtils.Tests/McMaster.Extensions.CommandLineUtils.Tests.csproj"
Original file line number Diff line number Diff line change 33 <PropertyGroup >
44 <TargetFramework >netstandard2.0</TargetFramework >
55 <GenerateDocumentationFile >true</GenerateDocumentationFile >
6+ <IsPackable >true</IsPackable >
67 <Description >Command-line parsing API. A drop-in replacement for Microsoft.Extensions.CommandLineUtils, plus extras.
78Commonly used types:
89
@@ -11,6 +12,8 @@ McMaster.Extensions.CommandLineUtils.CommandOption
1112 </Description >
1213 <PackageTags >commandline;parsing</PackageTags >
1314 <NoWarn >$(NoWarn);CS1591</NoWarn >
15+ <IncludeSymbols >true</IncludeSymbols >
16+ <IncludeSource >true</IncludeSource >
1417 </PropertyGroup >
1518
1619</Project >
Original file line number Diff line number Diff line change @@ -21,4 +21,7 @@ public void FindsTheDoNetPath()
2121 }
2222 }
2323}
24+ #elif NET461
25+ #else
26+ #error Update target frameworks
2427#endif
Original file line number Diff line number Diff line change 33 <PropertyGroup >
44 <TargetFrameworks >netcoreapp2.0;net461</TargetFrameworks >
55 <TargetFrameworks Condition =" '$(OS)' != 'Windows_NT' " >netcoreapp2.0</TargetFrameworks >
6- <IsPackable >false</IsPackable >
76 </PropertyGroup >
87
98 <ItemGroup >
You can’t perform that action at this time.
0 commit comments