-
-
Notifications
You must be signed in to change notification settings - Fork 39
46 lines (41 loc) · 1.27 KB
/
touchstone-comment.yaml
File metadata and controls
46 lines (41 loc) · 1.27 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
name: Continuous Benchmarks (Comment)
concurrency:
group: ${{ github.workflow }}-${{ github.run_id }}
cancel-in-progress: true
on:
workflow_run:
workflows: ["Continuous Benchmarks (Receive)"]
types: [completed]
jobs:
comment:
runs-on: ubuntu-latest
permissions:
actions: read
pull-requests: write
if: ${{ github.event.workflow_run.event == 'pull_request' }}
steps:
- name: Download Touchstone artifact
id: download
uses: actions/download-artifact@v8
with:
name: pr
github-token: ${{ github.token }}
repository: ${{ github.repository }}
run-id: ${{ github.event.workflow_run.id }}
# defensive since issues could cause commenting in random places
- name: Read PR number
id: pr
shell: bash
run: |
number="$(tr -cd '0-9' < ./NR)"
test -n "$number"
echo "number=$number" >> "$GITHUB_OUTPUT"
- name: Create or update sticky PR comment
id: comment
uses: marocchino/sticky-pull-request-comment@v3
with:
GITHUB_TOKEN: ${{ github.token }}
number_force: ${{ steps.pr.outputs.number }}
header: touchstone
path: ./info.txt
skip_unchanged: true