mirror of
https://github.com/jimeh/ozu.io.git
synced 2026-02-19 08:06:39 +00:00
Add Makefile for basic tasks
This commit is contained in:
28
Makefile
Normal file
28
Makefile
Normal file
@@ -0,0 +1,28 @@
|
||||
DIRS = $(shell go list ./... | grep -v /vendor/)
|
||||
|
||||
DEV_DEPS = github.com/kardianos/govendor \
|
||||
github.com/vektra/mockery/.../ \
|
||||
github.com/mailru/easyjson/...
|
||||
|
||||
test:
|
||||
@go test $(DIRS)
|
||||
|
||||
generate: dev-deps
|
||||
@go generate $(DIRS)
|
||||
|
||||
build:
|
||||
mkdir -p bin && go build -o bin/ozuio
|
||||
|
||||
run: build
|
||||
./bin/ozuio
|
||||
|
||||
install-vendor:
|
||||
go install ./vendor/...
|
||||
|
||||
dev-deps:
|
||||
@$(foreach DEP,$(DEV_DEPS),go get $(DEP);)
|
||||
|
||||
update-dev-deps:
|
||||
@$(foreach DEP,$(DEV_DEPS),go get -u $(DEP);)
|
||||
|
||||
.PHONY: test build generate run install-vendor dev-deps
|
||||
Reference in New Issue
Block a user