7 changed files with 7 additions and 61 deletions
@ -1,27 +0,0 @@ |
|||||
run: |
|
||||
deadline: 5m |
|
||||
skip-dirs: |
|
||||
# - test |
|
||||
# - bench |
|
||||
|
|
||||
linter-settings: |
|
||||
goconst: |
|
||||
min-len: 2 |
|
||||
min-occurrences: 2 |
|
||||
|
|
||||
linters: |
|
||||
enable: |
|
||||
- revive |
|
||||
- goconst |
|
||||
- gofmt |
|
||||
- goimports |
|
||||
- misspell |
|
||||
- unparam |
|
||||
|
|
||||
issues: |
|
||||
exclude-use-default: false |
|
||||
exclude-rules: |
|
||||
- path: _test.go |
|
||||
linters: |
|
||||
- errcheck |
|
||||
- revive |
|
||||
@ -1,26 +0,0 @@ |
|||||
# dev env https://www.dtm.pub/other/develop.html
|
|
||||
all: fmt lint test_redis |
|
||||
.PHONY: all |
|
||||
|
|
||||
fmt: |
|
||||
@gofmt -s -w ./ |
|
||||
|
|
||||
lint: |
|
||||
@golangci-lint run |
|
||||
|
|
||||
.PHONY: test |
|
||||
test: |
|
||||
@go test ./... |
|
||||
|
|
||||
test_redis: |
|
||||
TEST_STORE=redis go test ./... |
|
||||
|
|
||||
test_all: |
|
||||
TEST_STORE=redis go test ./... |
|
||||
TEST_STORE=boltdb go test ./... |
|
||||
TEST_STORE=mysql go test ./... |
|
||||
TEST_STORE=postgres go test ./... |
|
||||
|
|
||||
cover_test: |
|
||||
./helper/test-cover.sh |
|
||||
|
|
||||
@ -1,4 +1,3 @@ |
|||||
set -x |
set -x |
||||
|
|
||||
curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(go env GOPATH)/bin v1.53.3 |
go install github.com/mgechev/revive@latest && revive -config revive.toml ./... |
||||
$(go env GOPATH)/bin/golangci-lint run |
|
||||
|
|||||
Loading…
Reference in new issue