Skip to content

Commit

Permalink
CI: use ! cmd | grep '^' to check output
Browse files Browse the repository at this point in the history
Handling xargs option is troublesome...
  • Loading branch information
haya14busa committed Sep 2, 2016
1 parent cf2fbeb commit 4bde23f
Showing 1 changed file with 2 additions and 8 deletions.
10 changes: 2 additions & 8 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,9 @@ deps:
go get github.com/kisielk/errcheck
go get github.com/client9/misspell/cmd/misspell

# http://syohex.hatenablog.com/entry/20140702/1404250291
XARG_EMPTY=''
ifeq ("$(uname)", "LINUX")
XARG_EMPTY='-r'
endif

lint: deps
gofmt -d -s . | tee /dev/stderr | xargs $(XARG_EMPTY) false
golint ./... | tee /dev/stderr | xargs $(XARG_EMPTY) false
! gofmt -d -s . | grep '^' # exit 1 if any output given
! golint ./... | grep '^'
go vet ./...
errcheck -asserts -ignoretests -ignore 'Close'
misspell -error **/*.go **/*.md
Expand Down

0 comments on commit 4bde23f

Please sign in to comment.