CI: Move GetReleaseVersion to its own template

This commit is contained in:
DeeDeeG
2020-08-04 12:40:06 -04:00
committed by Amin Yahyaabadi
parent 4ddf0df65f
commit 727352adbc
4 changed files with 23 additions and 36 deletions

View File

@@ -1,16 +1,6 @@
jobs:
- job: GetReleaseVersion
pool:
vmImage: 'ubuntu-latest'
steps:
# This has to be done separately because VSTS inexplicably
# exits the script block after `npm install` completes.
- script: |
cd script/vsts
npm install
displayName: npm install
- script: node script/vsts/get-release-version.js --nightly
name: Version
# Import "GetReleaseVersion" job definition
- template: platforms/templates/get-release-version.yml
# Import OS-specific build definitions
- template: platforms/windows.yml

View File

@@ -0,0 +1,17 @@
jobs:
- job: GetReleaseVersion
pool:
vmImage: 'ubuntu-latest'
steps:
# This has to be done separately because VSTS inexplicably
# exits the script block after `npm ci` completes.
- script: |
cd script/vsts
npm ci
displayName: npm ci
- script: node script/vsts/get-release-version.js
name: Version
env:
REPO_OWNER: $(REPO_OWNER)
NIGHTLY_RELEASE_REPO: $(NIGHTLY_RELEASE_REPO)

View File

@@ -1,18 +1,8 @@
trigger: none # No CI builds, only PR builds
jobs:
- job: GetReleaseVersion
pool:
vmImage: 'ubuntu-latest'
steps:
# This has to be done separately because VSTS inexplicably
# exits the script block after `npm install` completes.
- script: |
cd script/vsts
npm install
displayName: npm install
- script: node script/vsts/get-release-version.js
name: Version
# Import "GetReleaseVersion" job definition
- template: platforms/templates/get-release-version.yml
# Import OS-specific build definitions
- template: platforms/windows.yml

View File

@@ -5,18 +5,8 @@ trigger:
pr: none # no PR triggers
jobs:
- job: GetReleaseVersion
pool:
vmImage: 'ubuntu-latest'
steps:
# This has to be done separately because VSTS inexplicably
# exits the script block after `npm install` completes.
- script: |
cd script/vsts
npm install
displayName: npm install
- script: node script/vsts/get-release-version.js
name: Version
# Import "GetReleaseVersion" job definition
- template: platforms/templates/get-release-version.yml
# Import OS-specific build definitions.
- template: platforms/windows.yml