mirror of https://github.com/FabricMC/yarn.git
Add and remove release/snapshot labels when updating branch (#2484)
* Update update-base.yml
* forgot i'm stupid
* Revert "forgot i'm stupid"
This reverts commit 0f98f227f6
.
* there is probably a better solution
This commit is contained in:
parent
62a05f3c86
commit
1118e1ae71
|
@ -33,6 +33,17 @@ jobs:
|
|||
try {
|
||||
// Updates the pull request with the latest upstream changes.
|
||||
await github.pulls.updateBranch({ owner, repo, pull_number })
|
||||
|
||||
// Checks if the branch is a development version
|
||||
if (contains(base, '-') || contains(base, 'w')) {
|
||||
await github.issues.addLabels({ owner, repo, issue_number, labels: ['snapshot'] });
|
||||
await github.issues.removeLabel({ owner, repo, issue_number, name: 'release' });
|
||||
// Otherwise it's a release
|
||||
} else {
|
||||
await github.issues.addLabels({ owner, repo, issue_number, labels: ['release'] });
|
||||
await github.issues.removeLabel({ owner, repo, issue_number, name: 'snapshot' });
|
||||
}
|
||||
|
||||
} catch (error) {
|
||||
// 422 is returned when there is a merge conflict
|
||||
if (error.status === 422) {
|
||||
|
|
Loading…
Reference in New Issue