Skip to content

Remove pull_request_template.md #279

Remove pull_request_template.md

Remove pull_request_template.md #279

Workflow file for this run

# This workflow will triage pull requests and apply a label based on the

Check warning on line 1 in .github/workflows/label.yml

View workflow run for this annotation

GitHub Actions / Labeler

Workflow execution policy warning (evaluate mode)

On November 2, 2026, GitHub will restrict `pull_request_target` on public repositories by default. To continue allowing the event trigger, configure an Actions policy. Learn more: https://gh.io/securely-using-pull_request_target#default-policy-for-pull_request_target
# paths that are modified in the pull request. It also applies the
# "AI assisted" label when a commit has an "Assisted-by:" trailer.
#
# To use this workflow, you will need to set up a .github/labeler.yml
# file with configuration. For more information, see:
# https://github.com/actions/labeler
name: Labeler
on: [pull_request_target]
jobs:
label:
runs-on: ubuntu-latest
permissions:
contents: read
pull-requests: write
steps:
- uses: actions/labeler@v7.0.0
with:
repo-token: "${{ secrets.GITHUB_TOKEN }}"
# Only reads the commit messages; the pull request is not checked out.
- name: Label pull requests with an Assisted-by trailer
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
REPO: ${{ github.repository }}
PR: ${{ github.event.pull_request.number }}
run: |
found=$(gh api "repos/$REPO/pulls/$PR/commits" --paginate \
--jq '.[].commit.message | split("\n")[] | ascii_downcase
| select(startswith("assisted-by:"))')
if [ -n "$found" ]; then
gh api -X POST "repos/$REPO/issues/$PR/labels" \
-f 'labels[]=AI assisted'
fi