-
Notifications
You must be signed in to change notification settings - Fork 2
39 lines (36 loc) · 963 Bytes
/
ci.yml
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
name: CI
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
ci:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v4
with:
go-version-file: ./go.mod
cache: true
- name: Download modules
run: go mod download
- name: Coverage
run: go test -v -race -cover -coverprofile=coverage ./...
- name: Report likely mistakes
run: go vet ./...
- name: Staticcheck
run: go install honnef.co/go/tools/cmd/staticcheck@latest && staticcheck ./...
- name: Build
run: CGO_ENABLED=0 go build -buildmode pie
- name: Codecov
uses: codecov/codecov-action@v3
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: ./coverage
flags: portal-role-sync
name: codecov-portal-role-sync
fail_ci_if_error: false
verbose: true