You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: .github/workflows/claude.yml
+20-7Lines changed: 20 additions & 7 deletions
Original file line number
Diff line number
Diff line change
@@ -20,7 +20,7 @@ jobs:
20
20
runs-on: ubuntu-latest
21
21
permissions:
22
22
contents: read
23
-
pull-requests: read
23
+
pull-requests: write # Required for posting inline review comments
24
24
issues: read
25
25
id-token: write
26
26
actions: read # Required for Claude to read CI results on PRs
@@ -40,11 +40,24 @@ jobs:
40
40
additional_permissions: |
41
41
actions: read
42
42
43
-
# Optional: Give a custom prompt to Claude. If this is not specified, Claude will perform the instructions specified in the comment that tagged it.
44
-
# prompt: 'Update the pull request description to include a summary of changes.'
43
+
# Enable inline review comments with suggestions for PR reviews
44
+
# When @claude is mentioned in PR comments, it will provide detailed inline feedback
45
+
prompt: |
46
+
Please review this PR and provide inline feedback using the GitHub review system. Follow these steps:
45
47
46
-
# Optional: Add claude_args to customize behavior and configuration
47
-
# See https://github.com/anthropics/claude-code-action/blob/main/docs/usage.md
48
-
# or https://docs.claude.com/en/docs/claude-code/cli-reference for available options
49
-
# claude_args: '--allowed-tools Bash(gh pr:*)'
48
+
1. **Start a review**: Use `mcp__github__create_pending_pull_request_review` to begin a pending review
49
+
2. **Get diff information**: Use `mcp__github__get_pull_request_diff` to understand the code changes and line numbers
50
+
3. **Add inline comments**: Use `mcp__github__add_comment_to_pending_review` for each specific piece of feedback on particular lines
51
+
4. **Submit the review**: Use `mcp__github__submit_pending_pull_request_review` with event type "COMMENT" (not "REQUEST_CHANGES") to publish all comments as a non-blocking review
52
+
53
+
When suggesting code changes, use GitHub's suggestion format with ```suggestion blocks so authors can apply changes directly.
54
+
55
+
# Enable GitHub MCP server tools for inline review comments
0 commit comments