Skip to content

Commit a5d3909

Browse files
committed
fix: update Claude Code Review workflow for improved functionality
- Adjusted checkout step to use pull request merge reference and disabled credential persistence. - Cleaned up whitespace for better readability. - Enhanced guidance on using the repository's CLAUDE.md for style and conventions. These changes aim to streamline the code review process and ensure proper integration with GitHub actions.
1 parent 610e30e commit a5d3909

File tree

1 file changed

+6
-5
lines changed

1 file changed

+6
-5
lines changed

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

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -17,18 +17,20 @@ jobs:
1717
# github.event.pull_request.user.login == 'external-contributor' ||
1818
# github.event.pull_request.user.login == 'new-developer' ||
1919
# github.event.pull_request.author_association == 'FIRST_TIME_CONTRIBUTOR'
20-
20+
2121
runs-on: ubuntu-latest
2222
permissions:
2323
contents: read
2424
pull-requests: read
2525
issues: read
2626
id-token: write
27-
27+
2828
steps:
2929
- name: Checkout repository
3030
uses: actions/checkout@v4
3131
with:
32+
ref: refs/pull/${{ github.event.number }}/merge
33+
persist-credentials: false
3234
fetch-depth: 1
3335

3436
- name: Run Claude Code Review
@@ -43,12 +45,11 @@ jobs:
4345
- Performance considerations
4446
- Security concerns
4547
- Test coverage
46-
48+
4749
Use the repository's CLAUDE.md for guidance on style and conventions. Be constructive and helpful in your feedback.
4850
4951
Use `gh pr comment` with your Bash tool to leave your review as a comment on the PR.
50-
52+
5153
# See https://github.com/anthropics/claude-code-action/blob/main/docs/usage.md
5254
# or https://docs.anthropic.com/en/docs/claude-code/sdk#command-line for available options
5355
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:*)"'
54-

0 commit comments

Comments
 (0)