Skip to content

Commit 9a82515

Browse files
StuMasonclaude
andcommitted
fix: Enable Bash tool for Claude code review action
The review was failing because Bash commands were denied, preventing Claude from reading the PR diff. Added allowed_tools to enable necessary tools. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
1 parent 3472adb commit 9a82515

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

.github/workflows/claude-code-review.yml

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,15 +26,17 @@ jobs:
2626
uses: anthropics/claude-code-action@v1
2727
with:
2828
claude_code_oauth_token: ${{ secrets.CLAUDE_CODE_OAUTH_TOKEN }}
29+
allowed_tools: "Bash,Read,Glob,Grep,Task,WebFetch"
2930
prompt: |
30-
Review this PR thoroughly. For each changed file:
31+
Review PR #${{ github.event.pull_request.number }} thoroughly.
3132
33+
First, run `gh pr diff ${{ github.event.pull_request.number }}` to see the changes.
34+
35+
Then for each changed file, analyze:
3236
1. **Summary**: What does this change do?
3337
2. **Security**: Any security concerns (auth, injection, secrets)?
3438
3. **Bugs**: Logic errors, edge cases, error handling?
3539
4. **Style**: Consistency with codebase patterns?
3640
5. **Improvements**: Suggestions for better approaches?
3741
38-
Be specific. Reference line numbers. If everything looks good, say why.
39-
40-
PR: ${{ github.repository }}/pull/${{ github.event.pull_request.number }}
42+
Be specific. Reference line numbers. Post your review as a PR comment using `gh pr comment`.

0 commit comments

Comments
 (0)