-
Notifications
You must be signed in to change notification settings - Fork 67
46 lines (46 loc) · 1.14 KB
/
golangci-lint.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
40
41
42
43
44
45
46
name: golangci-lint
on:
push:
tags:
- v*
branches:
- master
pull_request:
jobs:
golangci:
name: lint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: golangci-lint
uses: golangci/golangci-lint-action@v2
with:
version: v1.51.2
args: --enable gofmt,gocyclo,goimports,dupl,gosec --timeout 5m --skip-dirs=examples,test --skip-files=.*_test.go$
static-checks:
runs-on: ubuntu-latest
env:
GO111MODULE: on
steps:
- name: Set up Go
uses: actions/setup-go@v1
with:
go-version: 1.18
id: go
- name: Checkout Source
uses: actions/checkout@v2
- name: Fmt
run: |
bash scripts/ci/formatChecker.sh
- name: Misspell
run: |
go get -u github.com/client9/misspell/cmd/misspell
bash scripts/ci/formatChecker.sh
- name: Lint
run: |
go get -u golang.org/x/lint/golint
bash scripts/ci/goLintChecker.sh
- name: Cyclo
run: |
go get github.com/fzipp/gocyclo
bash scripts/ci/goCycloChecker.sh