[CI] test committed
This commit is contained in:
parent
2570a753e0
commit
dd94122915
2 changed files with 12 additions and 8 deletions
19
dist/index.js
vendored
19
dist/index.js
vendored
|
@ -1393,6 +1393,7 @@ function createOrUpdateBranch(git, commitMessage, base, branch, branchRemoteName
|
||||||
core.info(`Updated branch '${branch}'`);
|
core.info(`Updated branch '${branch}'`);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
result.action = 'not-updated';
|
||||||
core.info(`Branch '${branch}' is even with its remote and will not be updated`);
|
core.info(`Branch '${branch}' is even with its remote and will not be updated`);
|
||||||
}
|
}
|
||||||
// Check if the pull request branch is ahead of the base
|
// Check if the pull request branch is ahead of the base
|
||||||
|
@ -7718,14 +7719,16 @@ function createPullRequest(inputs) {
|
||||||
`HEAD:refs/heads/${inputs.branch}`
|
`HEAD:refs/heads/${inputs.branch}`
|
||||||
]);
|
]);
|
||||||
core.endGroup();
|
core.endGroup();
|
||||||
// Set the base. It would have been '' if not specified as an input
|
}
|
||||||
inputs.base = result.base;
|
// Set the base. It would have been '' if not specified as an input
|
||||||
if (result.hasDiffWithBase) {
|
inputs.base = result.base;
|
||||||
// Create or update the pull request
|
if (result.hasDiffWithBase) {
|
||||||
yield githubHelper.createOrUpdatePullRequest(inputs, baseRemote.repository, branchRepository);
|
// Create or update the pull request
|
||||||
}
|
yield githubHelper.createOrUpdatePullRequest(inputs, baseRemote.repository, branchRepository);
|
||||||
else {
|
}
|
||||||
// If there is no longer a diff with the base delete the branch
|
else {
|
||||||
|
// If there is no longer a diff with the base delete the branch
|
||||||
|
if (['updated', 'not-updated'].includes(result.action)) {
|
||||||
core.info(`Branch '${inputs.branch}' no longer differs from base branch '${inputs.base}'`);
|
core.info(`Branch '${inputs.branch}' no longer differs from base branch '${inputs.base}'`);
|
||||||
core.info(`Closing pull request and deleting branch '${inputs.branch}'`);
|
core.info(`Closing pull request and deleting branch '${inputs.branch}'`);
|
||||||
yield git.push([
|
yield git.push([
|
||||||
|
|
1
report.txt
Normal file
1
report.txt
Normal file
|
@ -0,0 +1 @@
|
||||||
|
1597825638
|
Loading…
Reference in a new issue