Skip to content

Commit

Permalink
Improve makefile
Browse files Browse the repository at this point in the history
  • Loading branch information
kotakanbe committed Oct 12, 2016
1 parent b964d19 commit 834c180
Showing 1 changed file with 17 additions and 4 deletions.
21 changes: 17 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,25 @@

SRCS = $(shell git ls-files '*.go')
PKGS = ./. ./config ./models ./report ./cveapi ./scan ./util ./commands ./cache
VERSION := $(shell git describe --tags --abbrev=0)
REVISION := $(shell git rev-parse --short HEAD)
LDFLAGS := -X 'main.version=$(VERSION)' \
-X 'main.revision=$(REVISION)'

all: test
setup:
go get github.com/Masterminds/glide

deps: setup
glide install

update: setup
glide update

# vendor:
# @ go get -v github.com/mjibson/party
# party -d external -c -u
bin: main.go deps
go build -ldflags "$(LDFLAGS)" -o $@ $<


all: test

lint:
@ go get -v github.com/golang/lint/golint
Expand Down

0 comments on commit 834c180

Please sign in to comment.