chore: trim output of branch correctly (#16307)

This commit is contained in:
Shelley Vohr
2019-01-07 12:24:18 -08:00
committed by GitHub
parent 9c7f6affc2
commit 854443a291

View File

@@ -52,7 +52,7 @@ async function nextNightly (v) {
let next = semver.valid(semver.coerce(v))
const pre = `nightly.${getCurrentDate()}`
const branch = await GitProcess.exec(['rev-parse', '--abbrev-ref', 'HEAD'], gitDir)
const branch = (await GitProcess.exec(['rev-parse', '--abbrev-ref', 'HEAD'], gitDir)).stdout.trim()
if (branch === 'master') {
next = semver.inc(await getLastMajorForMaster(), 'major')
} else if (isStable(v)) {