Files
dagu/Makefile
T
2022-05-16 16:11:39 +09:00

23 lines
355 B
Makefile

bin:
mkdir .bin
VERSION=$(shell date +'%y%m%d%H%M%S')
LDFLAGS=-X 'main.version=$(VERSION)'
.PHONY: build
build: bin
go build -ldflags="$(LDFLAGS)" -o ./bin/dagu ./cmd/
.PHONY: server
server: build
go run -ldflags="$(LDFLAGS)" ./cmd/ server
.PHONY: test
test: build
go test ./...
.PHONY: test-clean
test-clean:
go clean -testcache
go test ./...