Skip to content

Commit adbd592

Browse files
julien51claude
andauthored
ci: fix Claude Code Review — always post a comment (unlock-protocol#16341)
ci: replace opaque code-review plugin with direct review prompt The code-review plugin only posts comments when it finds issues, making it invisible on clean code. Replace with a direct prompt that always posts a review (LGTM or issues found). Also drops the plugin_marketplaces dependency entirely. Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
1 parent c6cbee5 commit adbd592

File tree

1 file changed

+12
-19
lines changed

1 file changed

+12
-19
lines changed

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

Lines changed: 12 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -3,21 +3,9 @@ name: Claude Code Review
33
on:
44
pull_request:
55
types: [opened, synchronize, ready_for_review, reopened]
6-
# Optional: Only run on specific file changes
7-
# paths:
8-
# - "src/**/*.ts"
9-
# - "src/**/*.tsx"
10-
# - "src/**/*.js"
11-
# - "src/**/*.jsx"
126

137
jobs:
148
claude-review:
15-
# Optional: Filter by PR author
16-
# if: |
17-
# github.event.pull_request.user.login == 'external-contributor' ||
18-
# github.event.pull_request.user.login == 'new-developer' ||
19-
# github.event.pull_request.author_association == 'FIRST_TIME_CONTRIBUTOR'
20-
219
runs-on: ubuntu-latest
2210
permissions:
2311
contents: read
@@ -36,12 +24,17 @@ jobs:
3624
uses: anthropics/claude-code-action@v1
3725
with:
3826
claude_code_oauth_token: ${{ secrets.CLAUDE_CODE_OAUTH_TOKEN }}
39-
plugin_marketplaces: 'https://github.com/anthropics/claude-code.git'
40-
plugins: 'code-review@claude-code-plugins'
41-
prompt: '/code-review:code-review --comment ${{ github.repository }}/pull/${{ github.event.pull_request.number }}'
42-
claude_args: '--allowedTools mcp__github_inline_comment__create_inline_comment,Bash(gh pr comment:*),Bash(gh pr diff:*),Bash(gh pr review:*),Bash(gh pr view:*),Bash(git diff:*),Bash(git log:*),Bash(git show:*),Read,Glob,Grep'
43-
display_report: 'true'
4427
use_sticky_comment: 'true'
45-
# See https://github.com/anthropics/claude-code-action/blob/main/docs/usage.md
46-
# or https://code.claude.com/docs/en/cli-reference for available options
28+
claude_args: '--allowedTools Bash(gh pr comment:*),Bash(gh pr diff:*),Bash(gh pr review:*),Bash(gh pr view:*),Bash(git diff:*),Bash(git log:*),Bash(git show:*),Read,Glob,Grep'
29+
prompt: |
30+
Review the code changes in PR #${{ github.event.pull_request.number }} of this repository.
31+
32+
Steps:
33+
1. Run `gh pr diff ${{ github.event.pull_request.number }}` to see the changes
34+
2. Run `gh pr view ${{ github.event.pull_request.number }}` to see the PR description
35+
3. Review the changes for bugs, security issues, and code quality problems
36+
4. Post your review using:
37+
`gh pr review ${{ github.event.pull_request.number }} --comment --body "YOUR_REVIEW"`
4738
39+
Always post a review comment, even if the code looks good (write "LGTM" with a brief summary in that case).
40+
Focus on real issues — not style nitpicks.

0 commit comments

Comments
 (0)