This repository has been archived by the owner on Nov 3, 2019. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
azure-pipelines.yml
68 lines (61 loc) · 2.74 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
variables:
Version: 3.0.$(Build.BuildId)
stages:
- stage: Build
jobs:
- job: Build
pool:
vmImage: Ubuntu 16.04
steps:
- task: UseDotNet@2
displayName: 'Install .Net Core 3.0'
inputs:
packageType: sdk
version: 3.0.100
includePreviewVersions: true
- task: DotNetCoreCLI@2
displayName: 'Restore packages'
inputs:
command: restore
projects: '**/*.csproj'
feedsToUse: 'select'
verbosityRestore: 'minimal'
vstsFeed: 'BioEngine'
- task: DotNetCoreCLI@2
displayName: 'Create package'
inputs:
command: custom
custom: 'pack'
projects: src/**/*.csproj
arguments: '--no-restore /p:Configuration=Release /p:PackageVersion=$(Version) --output $(Build.ArtifactStagingDirectory)'
- task: PublishPipelineArtifact@0
displayName: 'Publish package as artifact'
inputs:
artifactName: 'packages'
targetPath: '$(Build.ArtifactStagingDirectory)'
- stage: Deploy
dependsOn: Build
condition: and(succeeded(), eq(variables['build.sourceBranch'], 'refs/heads/master'))
jobs:
- job: Publish
pool:
vmImage: Ubuntu 16.04
steps:
- download: current
artifact: packages
- task: DotNetCoreCLI@2
displayName: 'Push package to internal feed'
inputs:
command: push
nuGetFeedType: internal
publishVstsFeed: BioEngine
versioningScheme: byEnvVar
versionEnvVar: Version
searchPatternPush: '$(Pipeline.Workspace)/**/*.nupkg'
- task: NuGetCommand@2
displayName: 'Push package to nuget'
inputs:
command: 'push'
packagesToPush: '$(Pipeline.Workspace)/**/*.nupkg'
nuGetFeedType: 'external'
publishFeedCredentials: 'BRC Nuget'