-
Notifications
You must be signed in to change notification settings - Fork 0
50 lines (42 loc) · 1.04 KB
/
pr-workflow.yaml
File metadata and controls
50 lines (42 loc) · 1.04 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
47
48
49
50
name: PR Workflow
on:
pull_request:
types: [synchronize, opened, reopened]
branches: ["main"]
permissions:
contents: read
jobs:
linter:
name: Linter
runs-on: ubuntu-latest
timeout-minutes: 10 # Sets a timeout of 10 minutes for this job (default is 1 minute)
steps:
- name: Checkout
uses: actions/checkout@v6
with:
persist-credentials: false
- uses: actions/setup-go@v6
with:
go-version: "^1.25"
cache: false
- name: Check Go Formatting
run: |
files=$(gofmt -l .) && echo $files && [ -z "$files" ]
- name: Golang CI Lint
uses: golangci/golangci-lint-action@v9
with:
version: v2.7.2
unit-tests:
name: Unit Tests
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v6
with:
persist-credentials: false
- uses: actions/setup-go@v6
with:
go-version: "^1.25"
- name: Unit tests
run: |
make test_unit