From 4ee4395fd8f60c6091c60ff9ebc7301a3fd889f1 Mon Sep 17 00:00:00 2001 From: vabatta <2137077+vabatta@users.noreply.github.com> Date: Fri, 28 Nov 2025 09:56:58 +0100 Subject: [PATCH 1/2] add pr and repo in the prompt --- .github/workflows/claude-code-review.yaml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/claude-code-review.yaml b/.github/workflows/claude-code-review.yaml index 1c455df..a618615 100644 --- a/.github/workflows/claude-code-review.yaml +++ b/.github/workflows/claude-code-review.yaml @@ -47,6 +47,9 @@ jobs: Use `gh pr comment` with your Bash tool to leave your review as a comment on the PR. + REPO: ${{ github.repository }} + PR NUMBER: ${{ github.event.pull_request.number }} + # See https://github.com/anthropics/claude-code-action/blob/main/docs/usage.md # or https://docs.anthropic.com/en/docs/claude-code/sdk#command-line for available options claude_args: '--allowed-tools "Bash(gh issue view:*),Bash(gh search:*),Bash(gh issue list:*),Bash(gh pr comment:*),Bash(gh pr diff:*),Bash(gh pr view:*),Bash(gh pr list:*)"' From a8e616456a25fe71990ed470a412c89a0cde5fee Mon Sep 17 00:00:00 2001 From: vabatta <2137077+vabatta@users.noreply.github.com> Date: Fri, 28 Nov 2025 14:38:28 +0100 Subject: [PATCH 2/2] allow labels to skip review --- .github/workflows/claude-code-review.yaml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/claude-code-review.yaml b/.github/workflows/claude-code-review.yaml index a618615..03fde78 100644 --- a/.github/workflows/claude-code-review.yaml +++ b/.github/workflows/claude-code-review.yaml @@ -2,7 +2,7 @@ name: Claude Code Review on: pull_request: - types: [opened, synchronize, ready_for_review] + types: [opened, synchronize, ready_for_review, labeled, unlabeled] # Optional: Only run on specific file changes # paths: # - "src/**/*.ts" @@ -14,7 +14,8 @@ jobs: claude-review: if: | github.event.pull_request.user.login == 'vabatta' && - github.event.pull_request.draft == false + github.event.pull_request.draft == false && + !contains(github.event.pull_request.labels.*.name, 'no-claude-review') timeout-minutes: 5 runs-on: ubuntu-latest