Check blocklist #46
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Check blocklist | |
on: | |
issues: | |
types: | |
- labeled | |
permissions: | |
contents: write | |
issues: write | |
jobs: | |
check-blocklist: | |
if: ${{ github.event.label.name == 'check blocklist' }} | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
ref: main | |
- name: Check blocklist | |
run: | | |
bash scripts/check.sh ${{ github.event.issue.body }} | |
# Update issue title | |
title="$(mawk -F 'Results for ' '{print $2}')" | |
gh issue edit ${{ github.event.issue.number }} -t "$title" | |
# Comment results | |
gh issue close ${{ github.event.issue.number }} -c \ | |
"$(cat data/TEMPLATE.md)" | |
env: | |
GH_TOKEN: ${{ github.token }} |