Skip to content

Commit d05a4cb

Browse files
committed
Add missing golangci lint target, add comment on why govet is disabled
1 parent 8340268 commit d05a4cb

File tree

2 files changed

+13
-0
lines changed

2 files changed

+13
-0
lines changed

.golangci.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,5 +23,6 @@ linters:
2323
- megacheck
2424
- varcheck
2525
- gochecknoglobals
26+
# Disabled due to: ":0: nilness: impossible condition: non-nil == nil (govet)"
2627
- govet
2728
fast: false

Makefile

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
LICENSEI_VERSION = 0.1.0
2+
GOLANGCI_VERSION = 1.16.0
23

34
all: license fmt vet
45

@@ -33,3 +34,14 @@ license-check: bin/licensei ## Run license check
3334
.PHONY: license-cache
3435
license-cache: bin/licensei ## Generate license cache
3536
bin/licensei cache
37+
38+
bin/golangci-lint: bin/golangci-lint-${GOLANGCI_VERSION}
39+
@ln -sf golangci-lint-${GOLANGCI_VERSION} bin/golangci-lint
40+
bin/golangci-lint-${GOLANGCI_VERSION}:
41+
@mkdir -p bin
42+
curl -sfL https://install.goreleaser.com/github.com/golangci/golangci-lint.sh | bash -s -- -b ./bin/ v${GOLANGCI_VERSION}
43+
@mv bin/golangci-lint $@
44+
45+
.PHONY: lint
46+
lint: bin/golangci-lint ## Run linter
47+
bin/golangci-lint run

0 commit comments

Comments
 (0)