Skip to content

Commit

Permalink
Make mergeProposalBranch asynchronous
Browse files Browse the repository at this point in the history
  • Loading branch information
codebytere committed May 5, 2020
1 parent 42a9d9f commit 946d16d
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions lib/promote_release.js
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ class ReleasePromotion {
const keyPath = await cli.prompt(
`Please enter the path to your ssh key (Default ${defaultKeyPath}): `,
{ questionType: 'input', defaultAnswer: defaultKeyPath });
await this.promoteAndSignRelease(keyPath);
this.promoteAndSignRelease(keyPath);

cli.separator();
cli.ok(`Release promotion for ${version} complete.\n`);
Expand Down Expand Up @@ -298,12 +298,12 @@ class ReleasePromotion {
const releaseBranch = `v${versionComponents.major}.x`;
const proposalBranch = `v${version}-proposal`;

runSync('git', ['checkout', releaseBranch]);
runSync('git', ['merge', '--ff-only', proposalBranch]);
runSync('git', ['push', 'upstream', releaseBranch]);
runSync('git', ['checkout', stagingBranch]);
runSync('git', ['rebase', releaseBranch]);
runSync('git', ['push', 'upstream', stagingBranch]);
await runAsync('git', ['checkout', releaseBranch]);
await runAsync('git', ['merge', '--ff-only', proposalBranch]);
await runAsync('git', ['push', 'upstream', releaseBranch]);
await runAsync('git', ['checkout', stagingBranch]);
await runAsync('git', ['rebase', releaseBranch]);
await runAsync('git', ['push', 'upstream', stagingBranch]);
}

pushReleaseTag() {
Expand All @@ -321,7 +321,7 @@ class ReleasePromotion {
// Since we've committed the Working On commit, the release
// commit will be 1 removed from tip-of-tree (e.g HEAD~1).
const releaseCommitSha = this.getCommitSha(1);
runSync('git', ['checkout', 'master']);
runAsync('git', ['checkout', 'master']);

// Pull master from upstream, in case it's not up-to-date.
runSync('git', ['pull', '--rebase', 'upstream', 'master']);
Expand Down

0 comments on commit 946d16d

Please sign in to comment.