-
Notifications
You must be signed in to change notification settings - Fork 4
56 lines (56 loc) · 1.21 KB
/
ci.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
53
54
55
56
name: Test
on: [push]
jobs:
setup:
runs-on: ubuntu-latest
steps:
- name: set up
uses: actions/setup-go@v2
with:
go-version: ^1.16
- name: check out
uses: actions/checkout@v2
- name: before cache
run: |
mkdir -p ~/go/pkg/mod
- name: Cache
uses: actions/[email protected]
with:
path: ~/go/pkg/mod
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
restore-keys: |
${{ runner.os }}-go-
build:
needs: setup
runs-on: ubuntu-latest
steps:
- name: set up
uses: actions/setup-go@v2
with:
go-version: ^1.16
- uses: actions/checkout@v2
- name: build
run: make build
lint:
needs: setup
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: golangci-lint
uses: golangci/golangci-lint-action@v2
with:
version: v1.42.1
test:
needs: setup
runs-on: ubuntu-latest
steps:
- name: set up
uses: actions/setup-go@v2
with:
go-version: ^1.16
- uses: actions/checkout@v2
- name: test
run: make test
- uses: shogo82148/actions-goveralls@v1
with:
path-to-profile: cover.out