cacert-boardvoting/Makefile

28 lines
784 B
Makefile
Raw Normal View History

2017-04-18 14:07:54 +00:00
VERSION := $(shell git describe --always --dirty=-dev)
COMMIT := $(shell git show-ref --hash refs/heads/master)
DATE := $(shell date --iso-8601=seconds --utc)
GOFILES = $(shell find . -type f -name '*.go')
UIFILES = package.json package-lock.json semantic.json $(shell find ui/semantic -type f )
2017-04-18 14:07:54 +00:00
all: cacert-boardvoting
cacert-boardvoting: ${GOFILES}
go build -o $@ -buildmode=pie -trimpath -ldflags " -s -w -X 'main.version=${VERSION}' -X 'main.commit=${COMMIT}' -X 'main.date=${DATE}'" ./cmd/boardvoting
test:
go test -v ./...
lint:
golangci-lint run
2017-04-18 14:07:54 +00:00
clean:
2022-10-15 19:31:11 +00:00
rm -rf cacert-boardvoting dist/ debian/README.md.gz
2017-04-18 14:07:54 +00:00
2022-10-15 18:18:37 +00:00
ui/static/semantic.min.css: ${UIFILES}
npm install
cd node_modules/fomantic-ui ; npx gulp build
2022-10-15 18:18:37 +00:00
ui: ui/static/semantic.min.css
2022-10-15 19:31:11 +00:00
.PHONY: clean all ui test lint