templatefile/Makefile
Philippe Caseiro 67e8485958 feat(api): adding api server code
templater can be used as a commmand line tool or as an api server.
2022-06-15 14:33:10 +02:00

38 lines
599 B
Makefile

LINT_ARGS ?= ./...
DESTDIR ?= "/usr/local"
bin:
GOOS=linux go build -o bin/templater-linux cmd/templater.go
upx bin/templater-linux
upx bin/templaster-server
install:
cp bin/templater-linux $(DESTDIR)/bin/templater
uninstall:
rm $(DESTDIR)/bin/templater
test: tidy
go clean -testcache
go test -mod=vendor -v ./...
lint:
golangci-lint run -e '.*/pkg/mod' -e ".*/go/src" --enable-all --disable lll $(LINT_ARGS)
tidy:
go mod tidy
vendor: tidy
go mod vendor
clean:
rm -rf ./bin
go clean -i -x -r -modcache
watch:
modd
.PHONY: clean generate vendor lint watch tidy bin/templater