Skip to content

Checklist

Checklist #28

Workflow file for this run

name: Checklist
on:
pull_request:
types:
- opened
- reopened
- edited
- synchronize
- ready_for_review
- labeled
workflow_run:
workflows: ["Labeler"]
types:
- completed
jobs:
detect:
name: Detect
runs-on: ubuntu-latest
outputs:
checked: ${{ steps.detect.outputs.checked }}
unchecked: ${{ steps.detect.outputs.unchecked }}
steps:
- name: Checkbox Trigger
id: detect
uses: karlderkaefer/github-action-checkbox-trigger@v1
with:
github-token: ${{ github.token }}
action: detect
- name: List changes
run: |
echo "checked=${{ steps.detect.outputs.checked }}"
echo "unchecked=${{ steps.detect.outputs.unchecked }}"
verify:
name: Verify
needs: [detect]
runs-on: ubuntu-latest
steps:
- name: Self-review
if: |
github.event.pull_request.draft == false &&
contains(needs.detect.outputs.unchecked, 'I have self-reviewed the code and added `AI-PR-Review` label.')
uses: actions/github-script@v7
with:
script: |
core.setFailed('Please self-review the code and address AI-PR-Review comments before requesting a review.')
- name: Changeset
if: |
github.event.workflow_run.conclusion == 'success' &&
github.event.pull_request.draft == false &&
!(contains(github.event.pull_request.labels.*.name, 'changeset-not-applicable') ||
contains(github.event.pull_request.labels.*.name, 'changeset-added'))
uses: actions/github-script@v7
with:
script: |
core.setFailed('Please add changeset or add the changeset-not-applicable label to the PR.')