forked from ncalc/ncalc
-
Notifications
You must be signed in to change notification settings - Fork 0
/
azure-pipelines.yml
61 lines (55 loc) · 1.45 KB
/
azure-pipelines.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
# Continuous Integration (CI) and Continuous Delivery (CD) for PW.NCalc
# Triggered when pushing to the "master" or "develop" branch
trigger:
batch: true
branches:
include:
- master
- develop
paths:
exclude:
- .gitignore
- CHANGELOG.md
- README.md
- LICENSE
# Triggered when opening a pull request (or pushing changes to it)
pr:
branches:
include:
- '*'
paths:
exclude:
- .gitignore
- CHANGELOG.md
- README.md
- LICENSE
# Use templates from the Utilities/PipelinesTemplates repository
resources:
repositories:
- repository: PipelinesTemplates
type: git
name: Utilities/PipelinesTemplates
# Pipeline name
name: PW.OpcUa.$(Build.BuildId)
stages:
- stage: Build
jobs:
- template: /DotNet/Build+Test.yml@PipelinesTemplates
parameters:
projectTitle: PW.NCalc
libraryTitle: Libraries
libraryProjects: |
**/NCalc.csproj
testProjects: |
**/NCalc.Tests.csproj
# Only publish package(s) from the main, master or a release branch
- ${{ if or(in(variables['Build.SourceBranch'], 'refs/heads/main', 'refs/heads/master'), startsWith(variables['Build.SourceBranch'], 'refs/heads/release/')) }}:
- stage: Publish
jobs:
- template: /DotNet/PublishNuGet.yml@PipelinesTemplates
parameters:
projectTitle: PW.NCalc
packageTitle: Packages
environment: Publish-PW_NCalc-Env
packagesToPublish: |
**/PW.NCalc.*.nupkg