-
Notifications
You must be signed in to change notification settings - Fork 0
Fix Claude Code Review workflow comment tooling #113
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
|
|
@@ -2,15 +2,43 @@ name: Claude Code Review | |||||
|
|
||||||
| on: | ||||||
| pull_request: | ||||||
| types: [opened, synchronize] | ||||||
| types: [opened, synchronize, ready_for_review, reopened] | ||||||
|
|
||||||
| jobs: | ||||||
| claude-review: | ||||||
| uses: shakacode/.github/.github/workflows/claude-code-review.yml@main | ||||||
| runs-on: ubuntu-latest | ||||||
| permissions: | ||||||
| contents: read | ||||||
| pull-requests: write | ||||||
| issues: write | ||||||
| id-token: write | ||||||
| secrets: | ||||||
| CLAUDE_CODE_OAUTH_TOKEN: ${{ secrets.CLAUDE_CODE_OAUTH_TOKEN }} | ||||||
|
|
||||||
| steps: | ||||||
| - name: Checkout repository | ||||||
| uses: actions/checkout@v6 | ||||||
| with: | ||||||
| fetch-depth: 1 | ||||||
|
|
||||||
| - name: Run Claude Code Review | ||||||
| id: claude-review | ||||||
| uses: anthropics/claude-code-action@v1 | ||||||
| with: | ||||||
| claude_code_oauth_token: ${{ secrets.CLAUDE_CODE_OAUTH_TOKEN }} | ||||||
|
||||||
| prompt: | | ||||||
| REPO: ${{ github.repository }} | ||||||
| PR NUMBER: ${{ github.event.pull_request.number }} | ||||||
|
|
||||||
| Please review this pull request with a focus on: | ||||||
| - Code quality and best practices | ||||||
| - Potential bugs or issues | ||||||
| - Security implications | ||||||
| - Performance considerations | ||||||
|
|
||||||
| Note: The PR branch is already checked out in the current working directory. | ||||||
|
|
||||||
| Use `gh pr comment` for top-level feedback. | ||||||
| Use `mcp__github_inline_comment__create_inline_comment` to highlight specific code issues. | ||||||
| Only post GitHub comments - don't submit review text as messages. | ||||||
|
|
||||||
| claude_args: | | ||||||
| --allowedTools "mcp__github_inline_comment__create_inline_comment,Bash(gh pr comment:*),Bash(gh pr diff:*),Bash(gh pr view:*)" | ||||||
|
||||||
| --allowedTools "mcp__github_inline_comment__create_inline_comment,Bash(gh pr comment:*),Bash(gh pr diff:*),Bash(gh pr view:*)" | |
| --allowed-tools "mcp__github_inline_comment__create_inline_comment,Bash(gh pr comment:*),Bash(gh pr diff:*),Bash(gh pr view:*)" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The workflow is missing the 'actions: read' permission that is present in the claude.yml workflow. According to the comment in claude.yml (line 26), this permission is "Required for Claude to read CI results on PRs". Consider adding this permission if Claude should be able to read CI results during code review, which would be valuable for providing more comprehensive feedback.