Commit d2942d7805
Unregistered key
Layout: unified · split
.github/workflows/pr-labeler.yml added +27
| @@ -0,0 +1,27 @@ | |||
| 1 | # Applies labels based on the pull request category | ||
| 2 | name: 🏷️ PR Labeler | ||
| 3 | on: | ||
| 4 | pull_request: | ||
| 5 | types: [opened, edited] | ||
| 6 | env: | ||
| 7 | IGNORE_STR: 'Addition / Amendment / Removal / Spelling or Grammar / Website Update / Other' | ||
| 8 | jobs: | ||
| 9 | label-pr: | ||
| 10 | runs-on: ubuntu-latest | ||
| 11 | permissions: write-all | ||
| 12 | steps: | ||
| 13 | - name: Apply Labels | ||
| 14 | if: ${{ !github.event.pull_request.body.includes(env.IGNORE_STR) }} | ||
| 15 | uses: Naturalclar/issue-action@v2.0.2 | ||
| 16 | with: | ||
| 17 | title-or-body: both | ||
| 18 | github-token: ${{ secrets.BOT_GITHUB_TOKEN || secrets.GITHUB_TOKEN }} | ||
| 19 | parameters: > | ||
| 20 | [ | ||
| 21 | {"keywords": ["Addition"], "labels": ["Addition"] }, | ||
| 22 | {"keywords": ["Amendment"], "labels": ["Amendment"] }, | ||
| 23 | {"keywords": ["Removal"], "labels": ["Removal"] }, | ||
| 24 | {"keywords": ["Spelling or Grammar"], "labels": ["Grammar"] }, | ||
| 25 | {"keywords": ["Website Update"], "labels": ["Website"] }, | ||
| 26 | {"keywords": ["Misc"], "labels": ["Misc"] } | ||
| 27 | ] | ||