-
Notifications
You must be signed in to change notification settings - Fork 458
52 lines (38 loc) · 1.2 KB
/
pullrequest.yaml
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
47
48
49
50
51
52
name: CI Build and Test for PR
permissions:
contents: read
on:
pull_request:
jobs:
check:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
- name: check format
run: make check_format
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
- name: build and test
run: make docker_tests
precommits:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
- uses: actions/setup-python@82c7e631bb3cdc910f68e0081d67478d79c6982d # v5.1.0
with:
python-version: "3.9"
- uses: actions/setup-go@cdcb36043654635271a94b9a6d1392de5bb323a7 # v5.0.1
with:
go-version: "1.21.5"
- name: run pre-commits
run: |
make precommit_install
pre-commit run -a
# If previous stage fails, print resolution steps
- if: ${{ failure() }}
name: Read for resolution steps
run: |
echo "Pre-commits failed! Run 'make precommit_install' then 'pre-commits run -a' to fix."
exit 1