Commit 23c9df3
ci: skip jobs requiring secrets when running from forks (anthropics#451)
## Summary
- Add `if` conditions to skip e2e test jobs (`test-e2e`,
`test-e2e-docker`, `test-examples`) when PRs come from forks
- Add `if` condition to skip `claude-review` job for fork PRs
- Prevents CI failures for external contributors since fork PRs don't
have access to repo secrets like `ANTHROPIC_API_KEY`
## Test plan
- [ ] Verify that unit tests still run for fork PRs (the `test` job has
no condition)
- [ ] Verify that e2e jobs are skipped for fork PRs
- [ ] Verify that e2e jobs still run for PRs from the main repo
- [ ] Verify that push to main still triggers all jobs
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-authored-by: Claude <[email protected]>1 parent 6b3044c commit 23c9df3
2 files changed
+8
-6
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
15 | | - | |
16 | | - | |
17 | | - | |
18 | | - | |
19 | | - | |
20 | | - | |
| 15 | + | |
| 16 | + | |
21 | 17 | | |
22 | 18 | | |
23 | 19 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
38 | 38 | | |
39 | 39 | | |
40 | 40 | | |
| 41 | + | |
| 42 | + | |
41 | 43 | | |
42 | 44 | | |
43 | 45 | | |
| |||
82 | 84 | | |
83 | 85 | | |
84 | 86 | | |
| 87 | + | |
| 88 | + | |
85 | 89 | | |
86 | 90 | | |
87 | 91 | | |
| |||
100 | 104 | | |
101 | 105 | | |
102 | 106 | | |
| 107 | + | |
| 108 | + | |
103 | 109 | | |
104 | 110 | | |
105 | 111 | | |
| |||
0 commit comments