Skip to content

Commit f709411

Browse files
authored
replace pull_request with pull_request_target (#79)
* Update swift.yml * Update swift.yml
1 parent fb9f85c commit f709411

File tree

1 file changed

+2
-23
lines changed

1 file changed

+2
-23
lines changed

.github/workflows/swift.yml

Lines changed: 2 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@ on:
55
branches: [ main ]
66
pull_request:
77
branches: [ main ]
8+
pull_request_target:
9+
branches: [ main ]
810

911
jobs:
1012
build_and_test_spm_mac:
@@ -47,12 +49,6 @@ jobs:
4749
- uses: webfactory/[email protected]
4850
with:
4951
ssh-private-key: ${{ secrets.SOVRAN_SSH_KEY }}
50-
# Workarounds for Xcode/SPM failing to get packages
51-
- run: sudo defaults write com.apple.dt.Xcode IDEPackageSupportUseBuiltinSCM YES
52-
- run: rm ~/.ssh/id_rsa || true
53-
- run: for ip in $(dig @8.8.8.8 bitbucket.org +short); do ssh-keyscan bitbucket.org,$ip; ssh-keyscan $ip; done 2>/dev/null >> ~/.ssh/known_hosts || true
54-
- run: for ip in $(dig @8.8.8.8 github.com +short); do ssh-keyscan github.com,$ip; ssh-keyscan $ip; done 2>/dev/null >> ~/.ssh/known_hosts || true
55-
# Xcodebuild will automatically build so no need to call it out specifically.
5652
- run: xcodebuild -scheme Segment-Package test -sdk iphonesimulator -destination 'platform=iOS Simulator,name=iPhone 11'
5753

5854
build_and_test_tvos:
@@ -65,12 +61,6 @@ jobs:
6561
- uses: webfactory/[email protected]
6662
with:
6763
ssh-private-key: ${{ secrets.SOVRAN_SSH_KEY }}
68-
# Workarounds for Xcode/SPM failing to get packages
69-
- run: sudo defaults write com.apple.dt.Xcode IDEPackageSupportUseBuiltinSCM YES
70-
- run: rm ~/.ssh/id_rsa || true
71-
- run: for ip in $(dig @8.8.8.8 bitbucket.org +short); do ssh-keyscan bitbucket.org,$ip; ssh-keyscan $ip; done 2>/dev/null >> ~/.ssh/known_hosts || true
72-
- run: for ip in $(dig @8.8.8.8 github.com +short); do ssh-keyscan github.com,$ip; ssh-keyscan $ip; done 2>/dev/null >> ~/.ssh/known_hosts || true
73-
# Xcodebuild will automatically build so no need to call it out specifically.
7464
- run: xcodebuild -scheme Segment-Package test -sdk appletvsimulator -destination 'platform=tvOS Simulator,name=Apple TV'
7565

7666
build_and_test_watchos:
@@ -83,12 +73,6 @@ jobs:
8373
- uses: webfactory/[email protected]
8474
with:
8575
ssh-private-key: ${{ secrets.SOVRAN_SSH_KEY }}
86-
# Workarounds for Xcode/SPM failing to get packages
87-
- run: sudo defaults write com.apple.dt.Xcode IDEPackageSupportUseBuiltinSCM YES
88-
- run: rm ~/.ssh/id_rsa || true
89-
- run: for ip in $(dig @8.8.8.8 bitbucket.org +short); do ssh-keyscan bitbucket.org,$ip; ssh-keyscan $ip; done 2>/dev/null >> ~/.ssh/known_hosts || true
90-
- run: for ip in $(dig @8.8.8.8 github.com +short); do ssh-keyscan github.com,$ip; ssh-keyscan $ip; done 2>/dev/null >> ~/.ssh/known_hosts || true
91-
# Xcodebuild will automatically build so no need to call it out specifically.
9276
- run: xcodebuild -scheme Segment-Package test -sdk watchsimulator -destination 'platform=watchOS Simulator,name=Apple Watch Series 5 - 40mm'
9377

9478
build_examples:
@@ -101,11 +85,6 @@ jobs:
10185
- uses: webfactory/[email protected]
10286
with:
10387
ssh-private-key: ${{ secrets.SOVRAN_SSH_KEY }}
104-
# Workarounds for Xcode/SPM failing to get packages
105-
- run: sudo defaults write com.apple.dt.Xcode IDEPackageSupportUseBuiltinSCM YES
106-
- run: rm ~/.ssh/id_rsa || true
107-
- run: for ip in $(dig @8.8.8.8 bitbucket.org +short); do ssh-keyscan bitbucket.org,$ip; ssh-keyscan $ip; done 2>/dev/null >> ~/.ssh/known_hosts || true
108-
- run: for ip in $(dig @8.8.8.8 github.com +short); do ssh-keyscan github.com,$ip; ssh-keyscan $ip; done 2>/dev/null >> ~/.ssh/known_hosts || true
10988
- name: build for ios simulator
11089
run: |
11190
cd Examples/apps/BasicExample

0 commit comments

Comments
 (0)