Skip to content

Commit a11b79a

Browse files
authored
Merge branch 'main' into network_alias
2 parents ae008ef + 5731c62 commit a11b79a

2 files changed

Lines changed: 18 additions & 12 deletions

File tree

Lines changed: 17 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,34 @@
11
name: Claude Code Review
22

3-
# pull_request_target runs in the context of the BASE repo (not the fork),
4-
# giving access to secrets even for PRs from forks.
5-
# Security note: the checkout below intentionally uses the base branch ref,
6-
# NOT the fork's code, to avoid executing untrusted code with repo secrets.
73
on:
8-
pull_request_target:
4+
pull_request:
95
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"
1012

1113
jobs:
1214
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+
1321
runs-on: ubuntu-latest
1422
permissions:
1523
contents: read
16-
pull-requests: write
17-
issues: write
24+
pull-requests: read
25+
issues: read
1826
id-token: write
1927

2028
steps:
21-
- name: Checkout base repository
29+
- name: Checkout repository
2230
uses: actions/checkout@v4
2331
with:
24-
# Explicitly checkout the base branch, not the fork's code.
25-
# This is required when using pull_request_target with fork PRs.
26-
ref: ${{ github.event.pull_request.base.sha }}
2732
fetch-depth: 1
2833

2934
- name: Run Claude Code Review
@@ -36,3 +41,4 @@ jobs:
3641
prompt: '/code-review:code-review ${{ github.repository }}/pull/${{ github.event.pull_request.number }}'
3742
# See https://github.com/anthropics/claude-code-action/blob/main/docs/usage.md
3843
# or https://code.claude.com/docs/en/cli-reference for available options
44+

.github/workflows/claude.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,5 +46,5 @@ jobs:
4646
# Optional: Add claude_args to customize behavior and configuration
4747
# See https://github.com/anthropics/claude-code-action/blob/main/docs/usage.md
4848
# or https://code.claude.com/docs/en/cli-reference for available options
49-
# claude_args: '--allowed-tools Bash(gh pr:*)'
49+
# claude_args: '--allowed-tools Bash(gh pr *)'
5050

0 commit comments

Comments
 (0)