chore: update release scripts to support sudowoodo (#14170)

Backports the totality of our release script changes to support sudowoodo. Also backports changes that have been made to a few other release script files in master after 3-0-x was cut with the purpose of keeping them in sync.
This commit is contained in:
Shelley Vohr 2018-08-17 12:01:10 -07:00 committed by GitHub
parent 44b0245ac4
commit 2ecdf4a0eb
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
15 changed files with 272 additions and 104 deletions

View file

@ -1,3 +1,5 @@
require('dotenv-safe').load()
const assert = require('assert')
const request = require('request')
const buildAppVeyorURL = 'https://windows-ci.electronjs.org/api/builds'
@ -44,7 +46,6 @@ async function makeRequest (requestOptions, parseResponse) {
}
async function circleCIcall (buildUrl, targetBranch, job, options) {
assert(process.env.CIRCLE_TOKEN, 'CIRCLE_TOKEN not found in environment')
console.log(`Triggering CircleCI to run build job: ${job} on branch: ${targetBranch} with release flag.`)
let buildRequest = {
'build_parameters': {
@ -77,7 +78,6 @@ async function circleCIcall (buildUrl, targetBranch, job, options) {
}
function buildAppVeyor (targetBranch, options) {
assert(process.env.APPVEYOR_TOKEN, 'APPVEYOR_TOKEN not found in environment')
const validJobs = Object.keys(appVeyorJobs)
if (options.job) {
assert(validJobs.includes(options.job), `Unknown AppVeyor CI job name: ${options.job}. Valid values are: ${validJobs}.`)
@ -139,7 +139,6 @@ async function buildVSTS (targetBranch, options) {
assert(vstsJobs.includes(options.job), `Unknown VSTS CI job name: ${options.job}. Valid values are: ${vstsJobs}.`)
}
console.log(`Triggering VSTS to run build on branch: ${targetBranch} with release flag.`)
assert(process.env.VSTS_TOKEN, 'VSTS_TOKEN not found in environment')
let environmentVariables = {}
if (!options.ghRelease) {