File tree Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Original file line number Diff line number Diff line change 1
1
name : Test Go Code Examples against Atlas
2
2
3
3
on :
4
- pull_request :
4
+ pull_request_target :
5
+ types : [opened, synchronize]
5
6
paths :
6
7
- " go/examples/**"
7
8
10
11
11
12
runs-on : ubuntu-latest
12
13
steps :
14
+ - name : Check access
15
+ if : ${{ github.event.pull_request.author_association != 'COLLABORATOR' }}
16
+ run : |
17
+ echo "Event not triggered by a collaborator."
18
+ exit 1
13
19
- uses : actions/checkout@v4
20
+ with :
21
+ ref : ${{ github.event.pull_request.head.sha }}
14
22
- name : Setup Go 1.21.x
15
23
uses : actions/setup-go@v5
16
24
with :
22
30
- name : Create environment file with connection string
23
31
run : |
24
32
cd go/
25
- echo "ATLAS_CONNECTION_STRING=\"${{secrets.ATLAS_CONNECTION_STRING }}\"" >> .env
33
+ echo "ATLAS_CONNECTION_STRING=\"${{secrets.GO_CONNECTION_STRING }}\"" >> .env
26
34
echo "ENV=\"Atlas\"" >> .env
27
35
- name : Run tests
28
36
run : |
You can’t perform that action at this time.
0 commit comments