-
Notifications
You must be signed in to change notification settings - Fork 1
/
azure-pipelines.yml
32 lines (29 loc) · 1.04 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
variables:
isMain: $[eq(variables['Build.SourceBranch'], 'refs/heads/main')]
isDependabot: $[or(contains(variables['Build.SourceBranch'], 'dependabot/'), contains(variables['Build.SourceBranch'], 'renovate/'))]
major: 1
minor: 7
patch: $[counter(format('{0}.{1}-{2}', variables['major'], variables['minor'], variables['isMain']), 0)]
version: $[format('{0}.{1}.{2}', variables['major'], variables['minor'], variables['patch'])]
npm_config_cache: $(Pipeline.Workspace)/.npm
pool:
vmImage: "ubuntu-latest"
stages:
- stage: Dev
condition: eq(variables.isMain, 'false')
jobs:
- job: Publish
steps:
- template: azure-pipelines.template.yml
parameters:
buildPostfix: ":dev"
additionalCommandArgs: "--share-with $(DEV_TEAM)"
baseUri: $(DEV_BASE_URI)
- stage: Prod
condition: eq(variables.isMain, 'true')
jobs:
- job: Publish
steps:
- template: azure-pipelines.template.yml
parameters:
setGitTag: true