Skip to content

Commit 21ca6fd

Browse files
committed
Add license link to package
1 parent fc7fc74 commit 21ca6fd

File tree

2 files changed

+18
-7
lines changed

2 files changed

+18
-7
lines changed

Directory.Build.props

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,11 @@
66
<Copyright>Copyright © Nate McMaster</Copyright>
77
<NeutralLanguage>en-US</NeutralLanguage>
88
<PackageRequireLicenseAcceptance>false</PackageRequireLicenseAcceptance>
9+
<PackageLicenseUrl>https://www.apache.org/licenses/LICENSE-2.0</PackageLicenseUrl>
910
<PackageProjectUrl>https://github.com/natemcmaster/CommandLineUtils</PackageProjectUrl>
1011
<RepositoryUrl>https://github.com/natemcmaster/CommandLineUtils.git</RepositoryUrl>
1112
<RepositoryType>git</RepositoryType>
1213
<IsPackable>false</IsPackable>
13-
<MinClientVersion>4.3.0</MinClientVersion>
1414
<NoPackageAnalysis>true</NoPackageAnalysis>
1515

1616
<AssemblyOriginatorKeyFile>$(MSBuildThisFileDirectory)build\StrongName.snk</AssemblyOriginatorKeyFile>
@@ -20,11 +20,13 @@
2020
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>
2121

2222
<VersionPrefix>2.0.0</VersionPrefix>
23-
<VersionSuffix>alpha</VersionSuffix>
23+
<BranchName Condition=" '$(BranchName)' == '' ">$(APPVEYOR_REPO_BRANCH)</BranchName>
24+
<VersionSuffix Condition="'$(BranchName)' != 'master'">alpha</VersionSuffix>
25+
<VersionSuffix Condition="'$(BranchName)' == 'master'">beta</VersionSuffix>
2426
<BuildNumber Condition=" '$(BuildNumber)' == '' ">$(APPVEYOR_BUILD_NUMBER)</BuildNumber>
2527
<BuildNumber Condition=" '$(BuildNumber)' == '' ">0</BuildNumber>
26-
<BranchName Condition=" '$(BranchName)' == '' ">$(APPVEYOR_REPO_BRANCH)</BranchName>
2728
<VersionSuffix Condition=" '$(VersionSuffix)' != '' ">$(VersionSuffix).$(BuildNumber)</VersionSuffix>
29+
<VersionSuffix Condition="'$(APPVEYOR_REPO_TAG)' == 'true'"></VersionSuffix>
2830
<VersionSuffix Condition=" '$(VersionSuffix)' != '' AND '$(BranchName)' != '' ">$(VersionSuffix)+$(BranchName)</VersionSuffix>
2931
</PropertyGroup>
3032

build.ps1

Lines changed: 13 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,10 @@
11
#!/usr/bin/env powershell
2+
[CmdletBinding(PositionalBinding = $false)]
23
param(
34
[ValidateSet('Debug', 'Release')]
4-
$Configuration = $null
5+
$Configuration = $null,
6+
[Parameter(ValueFromRemainingArguments = $true)]
7+
[string[]]$MSBuildArgs
58
)
69

710
Set-StrictMode -Version 1
@@ -30,6 +33,12 @@ $artifacts = "$PSScriptRoot/artifacts/"
3033

3134
Remove-Item -Recurse $artifacts -ErrorAction Ignore
3235

33-
exec dotnet restore
34-
exec dotnet pack -c $Configuration -o $artifacts
35-
exec dotnet test -c $Configuration "$PSScriptRoot/test/CommandLineUtils.Tests/McMaster.Extensions.CommandLineUtils.Tests.csproj"
36+
exec dotnet restore @MSBuildArgs
37+
exec dotnet pack `
38+
-c $Configuration `
39+
-o $artifacts `
40+
@MSBuildArgs
41+
exec dotnet test `
42+
-c $Configuration `
43+
"$PSScriptRoot/test/CommandLineUtils.Tests/McMaster.Extensions.CommandLineUtils.Tests.csproj" `
44+
@MSBuildArgs

0 commit comments

Comments
 (0)