Skip to content

Commit 17d2a4d

Browse files
Revert label & env based external contributor CI workflows (#181)
* Revert "Use environment protection for external PRs (#180)" This reverts commit 08ea6f4. * Revert label based CI workflow
1 parent 08ea6f4 commit 17d2a4d

File tree

3 files changed

+5
-21
lines changed

3 files changed

+5
-21
lines changed

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

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
name: Claude Code Review
22

33
on:
4-
pull_request_target:
4+
pull_request:
55
types: [opened, synchronize]
66
# Optional: Only run on specific file changes
77
# paths:
@@ -13,12 +13,9 @@ on:
1313
jobs:
1414
claude-review:
1515
# Skip review for automated "Version Packages" PRs created by changesets
16-
# For external PRs: requires manual approval via 'external-pr' environment
17-
# For internal PRs: runs automatically without approval
1816
if: github.event.pull_request.title != 'Version Packages'
1917

2018
runs-on: ubuntu-latest
21-
environment: ${{ github.event.pull_request.head.repo.full_name != github.repository && 'external-pr' || null }}
2219
permissions:
2320
contents: read
2421
pull-requests: read
@@ -29,7 +26,6 @@ jobs:
2926
- name: Checkout repository
3027
uses: actions/checkout@v4
3128
with:
32-
ref: ${{ github.event.pull_request.head.sha }}
3329
fetch-depth: 1
3430

3531
- name: Run Claude Code Review

.github/workflows/pkg-pr-new.yml

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ permissions:
55
pull-requests: write # Required for pkg.pr.new to comment on PRs
66

77
on:
8-
pull_request_target:
8+
pull_request:
99
types: [opened, synchronize, reopened]
1010
paths:
1111
- '**'
@@ -14,17 +14,13 @@ on:
1414

1515
jobs:
1616
publish-preview:
17-
# For external PRs: requires manual approval via 'external-pr' environment
18-
# For internal PRs: runs automatically without approval
1917
runs-on: ubuntu-latest
2018
timeout-minutes: 15
21-
environment: ${{ github.event.pull_request.head.repo.full_name != github.repository && 'external-pr' || null }}
2219

2320
steps:
2421
- name: Checkout code
2522
uses: actions/checkout@v4
2623
with:
27-
ref: ${{ github.event.pull_request.head.sha }}
2824
fetch-depth: 0
2925

3026
- name: Setup Node.js

.github/workflows/pullrequest.yml

Lines changed: 3 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,7 @@ permissions:
44
contents: read
55

66
on:
7-
pull_request_target:
8-
types: [opened, synchronize, reopened]
7+
pull_request:
98

109
concurrency:
1110
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
@@ -20,8 +19,6 @@ jobs:
2019
version: ${{ steps.get-version.outputs.version }}
2120
steps:
2221
- uses: actions/checkout@v4
23-
with:
24-
ref: ${{ github.event.pull_request.head.sha }}
2522

2623
- uses: actions/setup-node@v4
2724
with:
@@ -74,17 +71,12 @@ jobs:
7471
run: npm run test -w @repo/sandbox-container
7572

7673
# E2E tests against deployed worker
77-
# For external PRs: requires manual approval via 'external-pr' environment
78-
# For internal PRs: runs automatically without approval
7974
e2e-tests:
8075
needs: unit-tests
8176
timeout-minutes: 30
8277
runs-on: ubuntu-latest
83-
environment: ${{ github.event.pull_request.head.repo.full_name != github.repository && 'external-pr' || null }}
8478
steps:
8579
- uses: actions/checkout@v4
86-
with:
87-
ref: ${{ github.event.pull_request.head.sha }}
8880

8981
- uses: actions/setup-node@v4
9082
with:
@@ -105,7 +97,7 @@ jobs:
10597
- name: Set environment name
10698
id: env-name
10799
run: |
108-
if [ "${{ github.event_name }}" = "pull_request_target" ]; then
100+
if [ "${{ github.event_name }}" = "pull_request" ]; then
109101
echo "env_name=pr-${{ github.event.pull_request.number }}" >> $GITHUB_OUTPUT
110102
echo "worker_name=sandbox-e2e-test-worker-pr-${{ github.event.pull_request.number }}" >> $GITHUB_OUTPUT
111103
else
@@ -163,7 +155,7 @@ jobs:
163155

164156
# Cleanup: Delete test worker and container (only for PR environments)
165157
- name: Cleanup test deployment
166-
if: always() && github.event_name == 'pull_request_target'
158+
if: always() && github.event_name == 'pull_request'
167159
continue-on-error: true
168160
run: |
169161
cd tests/e2e/test-worker

0 commit comments

Comments
 (0)