Skip to content

Commit a58384b

Browse files
authored
Add Claude Code GitHub Workflow (#146)
* "Update Claude PR Assistant workflow" * "Update Claude Code Review workflow"
1 parent fd2ffc8 commit a58384b

File tree

2 files changed

+8
-21
lines changed

2 files changed

+8
-21
lines changed

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

Lines changed: 6 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ name: Claude Code Review
22

33
on:
44
pull_request:
5-
types: [opened, synchronize]
5+
types: [opened, synchronize, ready_for_review, reopened]
66
# Optional: Only run on specific file changes
77
# paths:
88
# - "src/**/*.ts"
@@ -27,7 +27,7 @@ jobs:
2727

2828
steps:
2929
- name: Checkout repository
30-
uses: actions/checkout@v6
30+
uses: actions/checkout@v4
3131
with:
3232
fetch-depth: 1
3333

@@ -36,22 +36,9 @@ jobs:
3636
uses: anthropics/claude-code-action@v1
3737
with:
3838
claude_code_oauth_token: ${{ secrets.CLAUDE_CODE_OAUTH_TOKEN }}
39-
prompt: |
40-
REPO: ${{ github.repository }}
41-
PR NUMBER: ${{ github.event.pull_request.number }}
42-
43-
Please review this pull request and provide feedback on:
44-
- Code quality and best practices
45-
- Potential bugs or issues
46-
- Performance considerations
47-
- Security concerns
48-
- Test coverage
49-
50-
Use the repository's CLAUDE.md for guidance on style and conventions. Be constructive and helpful in your feedback.
51-
52-
Use `gh pr comment` with your Bash tool to leave your review as a comment on the PR.
53-
39+
plugin_marketplaces: 'https://github.com/anthropics/claude-code.git'
40+
plugins: 'code-review@claude-code-plugins'
41+
prompt: '/code-review:code-review ${{ github.repository }}/pull/${{ github.event.pull_request.number }}'
5442
# See https://github.com/anthropics/claude-code-action/blob/main/docs/usage.md
55-
# or https://docs.claude.com/en/docs/claude-code/cli-reference for available options
56-
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:*)"'
43+
# or https://code.claude.com/docs/en/cli-reference for available options
5744

.github/workflows/claude.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ jobs:
2626
actions: read # Required for Claude to read CI results on PRs
2727
steps:
2828
- name: Checkout repository
29-
uses: actions/checkout@v6
29+
uses: actions/checkout@v4
3030
with:
3131
fetch-depth: 1
3232

@@ -45,6 +45,6 @@ jobs:
4545

4646
# Optional: Add claude_args to customize behavior and configuration
4747
# 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
48+
# or https://code.claude.com/docs/en/cli-reference for available options
4949
# claude_args: '--allowed-tools Bash(gh pr:*)'
5050

0 commit comments

Comments
 (0)