Skip to content

Commit

Permalink
Speeding up lint, adding slow-lint target
Browse files Browse the repository at this point in the history
Signed-off-by: Dave Henderson <[email protected]>
  • Loading branch information
hairyhenderson committed May 4, 2018
1 parent 73bd6ee commit ce4b3e3
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 4 deletions.
35 changes: 31 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -97,11 +97,38 @@ gomplate.png: gomplate.svg
cloudconvert -f png -c density=288 $^

lint:
gometalinter -j $(LINT_PROCS) --vendor --skip test --deadline 120s --disable gotype --enable gofmt --enable goimports --enable misspell --disable gas ./...
gometalinter --vendor --disable-all \
--enable=gas \
--enable=goconst \
--enable=gocyclo \
--enable=golint \
--enable=gotypex \
--enable=ineffassign \
--enable=vet \
--enable=vetshadow \
--enable=misspell \
--enable=goimports \
--enable=gofmt \
./...
gometalinter --vendor --skip test --disable-all \
--enable=deadcode \
./...

slow-lint:
gometalinter -j $(LINT_PROCS) --vendor --skip test --deadline 120s \
--disable gotype \
--enable gofmt \
--enable goimports \
--enable misspell \
./...
gometalinter -j $(LINT_PROCS) --vendor --deadline 120s \
--disable gotype --disable megacheck --disable deadcode --disable gas \
--enable gofmt --enable goimports --enable misspell \
./test/integration
--disable gotype \
--disable megacheck \
--disable deadcode \
--enable gofmt \
--enable goimports \
--enable misspell \
./test/integration
megacheck -tags integration ./test/integration

.PHONY: gen-changelog clean test build-x compress-all build-release build build-integration-image test-integration-docker gen-docs lint clean-images clean-containers docker-images
Expand Down
1 change: 1 addition & 0 deletions cmd/gomplate/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ func postRunExec(cmd *cobra.Command, args []string) error {
if len(args) > 0 {
name := args[0]
args = args[1:]
// nolint: gas
c := exec.Command(name, args...)
c.Stdin = os.Stdin
c.Stderr = os.Stderr
Expand Down

0 comments on commit ce4b3e3

Please sign in to comment.