44 push :
55 branches :
66 - main
7- pull_request_target :
7+ pull_request :
88 branches :
99 - main
1010
1111jobs :
1212 javascript :
1313 name : JavaScript
1414 runs-on : ubuntu-latest
15- if : " !contains(github.event.head_commit.message, '[skip ci]')"
1615 strategy :
1716 matrix :
1817 workspace :
2726 steps :
2827 - name : Checkout
2928 uses : actions/checkout@v3
30- with :
31- repository : ${{ github.event.pull_request.head.repo.full_name }}
32- ref : ${{ github.head_ref }}
3329 - name : Set up node
3430 uses : actions/setup-node@v3
3531 with :
5955 docker :
6056 name : Docker
6157 runs-on : ubuntu-latest
62- if : " !contains(github.event.head_commit.message, '[skip ci]')"
6358 strategy :
6459 matrix :
6560 workspace :
7469 steps :
7570 - name : Checkout
7671 uses : actions/checkout@v3
77- with :
78- repository : ${{ github.event.pull_request.head.repo.full_name }}
79- ref : ${{ github.head_ref }}
8072 - name : Set up docker buildx
8173 uses : docker/setup-buildx-action@v2
8274 - name : Set up node
@@ -116,7 +108,6 @@ jobs:
116108 url :
117109 name : URL
118110 runs-on : ubuntu-latest
119- if : " !contains(github.event.head_commit.message, '[skip ci]')"
120111 strategy :
121112 matrix :
122113 workspace :
@@ -127,9 +118,6 @@ jobs:
127118 steps :
128119 - name : Checkout
129120 uses : actions/checkout@v3
130- with :
131- repository : ${{ github.event.pull_request.head.repo.full_name }}
132- ref : ${{ github.head_ref }}
133121 - name : Set up node
134122 uses : actions/setup-node@v3
135123 with :
@@ -155,28 +143,25 @@ jobs:
155143 implementations/${{ matrix.workspace.name }}/report.json
156144
157145 report :
146+ permissions :
147+ contents : write
148+ pull-requests : write
158149 name : Report
159150 runs-on : ubuntu-latest
160151 if : ${{ !contains(github.event.head_commit.message, '[skip ci]') }}
161152 needs : [javascript, docker, url]
162153 steps :
163154 - name : Checkout
164155 uses : actions/checkout@v3
165- with :
166- repository : ${{ github.event.pull_request.head.repo.full_name }}
167- ref : ${{ github.head_ref }}
168156 - name : Download audit reports
169157 uses : actions/download-artifact@v3
170158 with :
171159 name : audit-reports
172160 - name : Render servers table
173161 run : node scripts/render-servers-table.mjs
174- - name : Diff
175- run : git diff --minimal
176- - name : Commit
177- run : |
178- git config user.name "github-actions[bot]"
179- git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
180- [ -z "$(git status --porcelain)" ] \
181- && echo "::notice::Nothing new to report." \
182- || (git add . && git commit -m "docs(implementations): audit report [skip ci]" && git push)
162+ - name : Create Pull Request
163+ uses : peter-evans/create-pull-request@v7
164+ with :
165+ title : Audit Report
166+ body : New audit report available.
167+ commit-message : ' docs(implementations): audit report'
0 commit comments