feat: scope check for babysit-pr, extract babysit-open-prs skill #262
This file contains hidden or 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: Claude Code Review | |
| on: | |
| pull_request: | |
| types: [opened, synchronize, ready_for_review, reopened] | |
| jobs: | |
| claude-review: | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: read | |
| pull-requests: write | |
| issues: read | |
| actions: write | |
| id-token: write | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 1 | |
| - name: Run Claude Code Review | |
| id: claude-review | |
| uses: anthropics/claude-code-action@v1.0.88 | |
| with: | |
| claude_code_oauth_token: ${{ secrets.CLAUDE_CODE_OAUTH_TOKEN }} | |
| use_sticky_comment: true | |
| track_progress: true | |
| allowed_bots: 'claude,claude[bot]' | |
| prompt: | | |
| REPO: ${{ github.repository }} | |
| PR NUMBER: ${{ github.event.pull_request.number }} | |
| Review this pull request. For each changed skill file: | |
| - Check that the frontmatter (name, description) is accurate and well-written | |
| - Flag any hardcoded secrets, tokens, or personal data that should be env vars | |
| - Note any broken references (paths, tool names, commands that don't exist) | |
| - Call out anything that contradicts how the skill actually works | |
| Keep feedback concise and actionable. Skip praise. | |
| Use inline comments for specific code issues. | |
| Use `gh pr comment` for top-level feedback. | |
| If everything looks good and there are no issues, post a comment saying "LGTM" followed by one sentence summarizing what you reviewed. | |
| REVIEW SUBMISSION: | |
| After completing your review, submit a formal GitHub review using gh pr review: | |
| - If you found issues: `gh pr review ${{ github.event.pull_request.number }} --request-changes --body "Summary of issues found"` | |
| - If LGTM: `gh pr review ${{ github.event.pull_request.number }} --approve --body "LGTM - brief summary"` | |
| If gh pr review fails (e.g. permissions), fall back to posting a comment with `gh pr comment` instead. | |
| claude_args: | | |
| --allowedTools "mcp__github_inline_comment__create_inline_comment,Bash(gh pr comment:*),Bash(gh pr diff:*),Bash(gh pr view:*),Bash(gh pr review:*)" | |
| --model claude-opus-4-6 | |
| --fallback-model claude-sonnet-4-6 |