File: Makefile

package info (click to toggle)
golang-github-masterminds-vcs-dev 1.12.0-4
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, bullseye, buster, forky, sid, trixie
  • size: 216 kB
  • sloc: makefile: 37
file content (41 lines) | stat: -rw-r--r-- 975 bytes parent folder | download | duplicates (2)
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
.PHONY: setup
setup:
	go get -u gopkg.in/alecthomas/gometalinter.v1
	gometalinter.v1 --install

.PHONY: test
test: validate lint
	@echo "==> Running tests"
	go test -v

.PHONY: validate
validate:
# misspell finds the work adresář (used in bzr.go) as a mispelling of
# address. It finds adres. An issue has been filed at
# https://github.com/client9/misspell/issues/99. In the meantime adding
# adres to the ignore list.
	@echo "==> Running static validations"
	@gometalinter.v1 \
	  --disable-all \
	  --linter "misspell:misspell -i adres -j 1 {path}/*.go:PATH:LINE:COL:MESSAGE" \
	  --enable deadcode \
	  --severity deadcode:error \
	  --enable gofmt \
	  --enable gosimple \
	  --enable ineffassign \
	  --enable misspell \
	  --enable vet \
	  --tests \
	  --vendor \
	  --deadline 60s \
	  ./... || exit_code=1

.PHONY: lint
lint:
	@echo "==> Running linters"
	@gometalinter.v1 \
	  --disable-all \
	  --enable golint \
	  --vendor \
	  --deadline 60s \
	  ./... || :