-
Notifications
You must be signed in to change notification settings - Fork 16
41 lines (37 loc) · 949 Bytes
/
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
name: ci
on:
push:
branches:
- "*"
- main
pull_request:
permissions:
contents: write
security-events: write
# Optional: allow read access to pull request. Use with `only-new-issues` option.
pull-requests: read
jobs:
golangci:
name: lint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-go@v4
with:
go-version: '1.21'
cache: false
- name: Run tests
run: go test ./... -coverprofile=coverage.out -coverpkg=./... -covermode=atomic
- name: golangci-lint
uses: golangci/golangci-lint-action@v3
with:
version: v1.54
args: -v --config=.ci.yml
skip-pkg-cache: true
skip-build-cache: true
- name: Static check
uses: dominikh/[email protected]
with:
version: "2023.1.6"
install-go: false
cache-key: '1.21'