This repository has been archived by the owner on Apr 18, 2023. It is now read-only.
/
appveyor.yml
97 lines (74 loc) · 3.02 KB
/
appveyor.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
#---------------------------------------------#
# build/environment configuration #
#---------------------------------------------#
version: '{build}'
build:
project: Repositive.sln
verbosity: minimal
image: Visual Studio 2019
configuration: Release
platform: Any CPU
cache:
- '%LocalAppData%\NuGet\v3-cache' # NuGet v3
environment:
certificate_pass:
secure: vOCLLinDZ51qdMw/T43JH1w4v2bWbdMVfEGCnC2il/c=
#-------------------------------------#
# pre-build configuration #
#-------------------------------------#
before_build:
- ps: |
$props = ([xml](Get-Content "Directory.Build.props")).Project.PropertyGroup
$vPrefix = $props.VersionPrefix
$vSuffix = $props.VersionSuffix
$releaseNotes = if ($props.PackageReleaseNotes.GetType() -eq [System.Xml.XmlElement]) { $props.PackageReleaseNotes.InnerText } else { $props.PackageReleaseNotes }
$env:fullVersion = @{ $true = "$($vPrefix)-$($vSuffix)"; $false = $($vPrefix) }[-not ([string]::IsNullOrEmpty($vSuffix))]
$env:isPreRelease = @{ $true = "true"; $false = "false" }[-not ([string]::IsNullOrEmpty($vSuffix))]
$env:releaseNotes = @{ $true = $releaseNotes.Replace("`n", '\n').TrimEnd().Trim('\n'); $false = "$env:fullVersion release!" }[-not ([string]::IsNullOrEmpty($releaseNotes))]
Update-AppveyorBuild -Version "$env:fullVersion Build-$env:APPVEYOR_BUILD_VERSION"
- ps: dotnet restore
- ps: |
Start-Process -FilePath "$env:APPVEYOR_BUILD_FOLDER\SnInstallPfx.exe" -ArgumentList "$env:APPVEYOR_BUILD_FOLDER\RepositiveKey.pfx $env:certificate_pass" -NoNewWindow
#-----------------------------------------#
# build trigger configuration #
#-----------------------------------------#
skip_commits:
files:
- '**/*.md'
- 'license'
skip_tags: false
#-----------------------------------#
# publish configuration #
#-----------------------------------#
nuget:
disable_publish_on_pr: true
#---------------------------------#
# artifacts configuration #
#---------------------------------#
artifacts:
- path: Repositive.Abstractions/bin/$(configuration)/Binaries
name: Repositive.Abstractions.$(fullVersion)
type: zip
- path: Repositive.EntityFrameworkCore/bin/$(configuration)/Binaries
name: Repositive.EntityFrameworkCore.$(fullVersion)
type: zip
- path: Repositive.Abstractions/bin/$(configuration)/Package/*.nupkg
- path: Repositive.EntityFrameworkCore/bin/$(configuration)/Package/*.nupkg
#---------------------------------#
# deploy configuration #
#---------------------------------#
deploy:
- provider: GitHub
tag: $(APPVEYOR_REPO_TAG_NAME)
description: $(releaseNotes)
draft: false
prerelease: $(isPreRelease)
auth_token:
secure: 17uIp5Xz3DUfAUcfU6n/DajZ45rm5HVKrhTYVYJ4Z8XocWZvtSzhfZTfak6P6emy
on:
APPVEYOR_REPO_TAG: true
- provider: NuGet
api_key:
secure: pF8W2j/TXfR8dLUpvBIabRDxkz0ye8u+cCQrsWOczf5C6QiyRKWY8M6dvbW1fAcK
on:
APPVEYOR_REPO_TAG: true