-
Notifications
You must be signed in to change notification settings - Fork 0
/
azure-pipelines.yml
74 lines (59 loc) · 1.79 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
62
63
64
65
66
67
68
69
70
71
72
73
74
# ASP.NET Core
# Build and test ASP.NET Core projects targeting .NET Core.
# Add steps that run tests, create a NuGet package, deploy, and more:
# https://docs.microsoft.com/azure/devops/pipelines/languages/dotnet-core
name: $(BuildDefinitionName)_$(Year:yyyy).$(Month).$(DayOfMonth)$(Rev:.r)
trigger:
- master
- release/*
pool:
vmImage: Ubuntu-latest
resources:
repositories:
- repository: templates
type: git
name: neolution-pipelines/pipeline-templates
variables:
BuildConfiguration: 'Release'
steps:
- task: UseDotNet@2
displayName: Install .NET Core SDK
inputs:
packageType: 'sdk'
version: '6.x'
- task: gitversion/setup@0
displayName: Install GitVersion
inputs:
versionSpec: '5.x'
- task: gitversion/execute@0
displayName: Execute GitVersion
- task: PowerShell@2
displayName: Update Build Number
inputs:
targetType: 'inline'
script: 'Write-Host "##vso[build.updatebuildnumber]$(NuGetVersion)"'
- task: DotNetCoreCLI@2
displayName: Restore
inputs:
command: restore
projects: '**/*.csproj'
vstsFeed: 'dc68f94e-847b-4595-86ba-405d5744b21d'
- task: DotNetCoreCLI@2
displayName: Build
inputs:
projects: '**/*.csproj'
arguments: '--configuration $(BuildConfiguration)'
- template: testing/unittests.yml@templates
- task: DotNetCoreCLI@2
displayName: Pack
inputs:
command: pack
packagesToPack: '**/Neolution.Extensions.Caching.Abstractions.csproj;**/Neolution.Extensions.Caching.RedisHybrid.csproj;**/Neolution.Extensions.Caching.InMemory.csproj;**/Neolution.Extensions.Caching.Distributed.csproj'
nobuild: true
versioningScheme: byEnvVar
versionEnvVar: NuGetVersion
- task: DotNetCoreCLI@2
displayName: Push
inputs:
command: push
publishVstsFeed: 'dc68f94e-847b-4595-86ba-405d5744b21d'