Skip to content

Commit

Permalink
Fix find-affected-packages logging. Fix Nightly build. (tensorflow#2908)
Browse files Browse the repository at this point in the history
BUG
INTERNAL
* Fix find-affected-packages logging.

* Fix Nightly build.
  • Loading branch information
lina128 committed Mar 15, 2020
1 parent 99e15f7 commit 8c5c145
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions scripts/find-affected-packages.js
Expand Up @@ -43,8 +43,10 @@ if (commitSha == null) {
if (branchName == null) {
branchName = exec(`git rev-parse --abbrev-ref HEAD`).stdout.trim();
}
if (baseBranch == null) {
// For Nightly build, baseBranch is null. We use master for Nightly build.

// For Nightly build, baseBranch is one of the falsey values. We use master
// for Nightly build.
if (!baseBranch) {
baseBranch = 'master';
}
console.log('commitSha: ', commitSha);
Expand Down Expand Up @@ -129,7 +131,7 @@ if (!triggerAllBuilds) {
});
});

triggeredBuilds.push(Array.from(affectedBuilds));
triggeredBuilds.push(...affectedBuilds);
}

// Filter the triggered builds to log by whether a cloudbuild.yml file
Expand Down

0 comments on commit 8c5c145

Please sign in to comment.