Skip to content

Commit 776f0ec

Browse files
mmorel-35knqyf263
andauthored
ci(lint) : setup golangci-lint-action (fanal#256)
* build(lint): setup golangci-lint-action Signed-off-by: Matthieu MOREL <[email protected]> * skip go installation Co-authored-by: knqyf263 <[email protected]>
1 parent 0523fbc commit 776f0ec

File tree

2 files changed

+27
-1
lines changed

2 files changed

+27
-1
lines changed

.github/workflows/test.yml

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,22 @@ on:
55
- main
66
pull_request:
77
jobs:
8+
lint:
9+
name: Lint
10+
runs-on: ubuntu-latest
11+
steps:
12+
- name: Setup go
13+
uses: actions/setup-go@v2
14+
with:
15+
go-version: 1.16
16+
- name: Checkout repository
17+
uses: actions/checkout@v2
18+
- name: Setup golangci-lint
19+
uses: golangci/golangci-lint-action@v2
20+
with:
21+
version: v1.43
22+
args : --verbose
23+
skip-go-installation: true
824
unittest:
925
name: Unit Test
1026
runs-on: ubuntu-latest
@@ -22,7 +38,6 @@ jobs:
2238
run: sudo apt-get update && sudo apt-get install libdb-dev
2339
- name: Run unit tests
2440
run: make test
25-
2641
integration:
2742
name: Integration Test
2843
runs-on: ubuntu-latest

.golangci.yml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
run:
2+
timeout: 5m
3+
linters:
4+
disable:
5+
- errcheck
6+
- gosimple
7+
- govet
8+
- ineffassign
9+
- staticcheck
10+
- structcheck
11+
- unused

0 commit comments

Comments
 (0)