Skip to content

Commit 34e3e30

Browse files
committed
chore: run code and docs review out of a single claude-review.yml gh
workflow
1 parent 3d52cd3 commit 34e3e30

3 files changed

Lines changed: 51 additions & 60 deletions

File tree

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

Lines changed: 0 additions & 29 deletions
This file was deleted.

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

Lines changed: 0 additions & 31 deletions
This file was deleted.
Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
name: PR Reviews with Claude Code
2+
3+
permissions:
4+
contents: read
5+
pull-requests: write
6+
7+
on:
8+
pull_request:
9+
types: [opened, synchronize, labeled]
10+
11+
jobs:
12+
review:
13+
runs-on: ubuntu-latest
14+
steps:
15+
- name: Checkout repository
16+
uses: actions/checkout@v4
17+
with:
18+
fetch-depth: 1
19+
20+
- name: Filter paths
21+
uses: dorny/paths-filter@v3
22+
id: filter
23+
with:
24+
filters: |
25+
code:
26+
- 'src/**'
27+
docs:
28+
- 'docs/**/*.md'
29+
- 'docs/**/*.csv'
30+
31+
- name: Run Claude Code (code)
32+
if: steps.filter.outputs.code == 'true'
33+
id: claude
34+
uses: anthropics/claude-code-action@a3ff61d47aa5118a43b33ae44c4087d9eb51111a
35+
with:
36+
anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY }}
37+
github_token: ${{ secrets.GITHUB_TOKEN }}
38+
prompt: "/review-code-pr REPO: ${{ github.repository }} PR_NUMBER: ${{ github.event.pull_request.number }}"
39+
claude_args: |
40+
--allowedTools "mcp__github_inline_comment__create_inline_comment,Bash(gh pr comment:*)"
41+
42+
- name: Run Claude Code (docs)
43+
if: steps.filter.outputs.docs == 'true'
44+
id: claude
45+
uses: anthropics/claude-code-action@a3ff61d47aa5118a43b33ae44c4087d9eb51111a
46+
with:
47+
anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY }}
48+
github_token: ${{ secrets.GITHUB_TOKEN }}
49+
prompt: "/review-helpdot-pr REPO: ${{ github.repository }} PR_NUMBER: ${{ github.event.pull_request.number }}"
50+
claude_args: |
51+
--allowedTools "mcp__github_inline_comment__create_inline_comment,Bash(gh pr comment:*)"

0 commit comments

Comments
 (0)