Levitate: use a custom breaking change label (#48494)

* chore: temporarily rename the breaking-change label assigned by Levitate

* chore: use 'levitate breaking change' as a label
This commit is contained in:
Levente Balogh 2022-04-29 14:44:50 +02:00 committed by GitHub
parent 1667a7c0da
commit 5283a8b13d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -61,7 +61,7 @@ jobs:
const script = require('./.github/workflows/scripts/json-file-to-job-output.js');
await script({ core, filePath });
- name: Check if "breaking change" label exists
- name: Check if "levitate breaking change" label exists
id: does-label-exist
uses: actions/github-script@v6
env:
@ -74,7 +74,7 @@ jobs:
repo: context.repo.repo,
});
const labels = data.map(({ name }) => name);
const doesExist = labels.includes('breaking change');
const doesExist = labels.includes('levitate breaking change');
return doesExist ? 1 : 0;
@ -117,7 +117,7 @@ jobs:
env:
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_LEVITATE_WEBHOOK_URL }}
- name: Add "breaking change" label
- name: Add "levitate breaking change" label
if: ${{ steps.levitate-run.outputs.exit_code == 1 && steps.does-label-exist.outputs.result == 0 }}
uses: actions/github-script@v6
env:
@ -129,10 +129,10 @@ jobs:
issue_number: process.env.PR_NUMBER,
owner: context.repo.owner,
repo: context.repo.repo,
labels: ['breaking change']
labels: ['levitate breaking change']
})
- name: Remove "breaking change" label
- name: Remove "levitate breaking change" label
if: ${{ steps.levitate-run.outputs.exit_code == 0 && steps.does-label-exist.outputs.result == 1 }}
uses: actions/github-script@v6
env:
@ -144,7 +144,7 @@ jobs:
issue_number: process.env.PR_NUMBER,
owner: context.repo.owner,
repo: context.repo.repo,
name: 'breaking change'
name: 'levitate breaking change'
})
# This is very weird, the actual request goes through (comes back with a 201), but does not assign the team.