123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566 |
- LDFLAGS += -X "gitote/gitote/pkg/setting.BuildTime=$(shell date -u '+%Y-%m-%d %I:%M:%S %Z')"
- LDFLAGS += -X "gitote/gitote/pkg/setting.BuildGitHash=$(shell git rev-parse HEAD)"
- DATA_FILES := $(shell find conf | sed 's/ /\\ /g')
- LESS_FILES := $(wildcard public/less/gitote.less public/less/_*.less)
- GENERATED := pkg/bindata/bindata.go public/css/gitote.min.css
- OS := $(shell uname)
- TAGS = ""
- BUILD_FLAGS = "-v"
- NOW = $(shell date -u '+%Y%m%d%I%M%S')
- GOVET = go tool vet -composites=false -methods=false -structtags=false
- .PHONY: build bindata clean
- .IGNORE: public/css/gitote.min.css
- all: build
- check: test
- web: build
- ./gitote web
- govet:
- $(GOVET) gitote.go
- $(GOVET) models pkg routes
- build: $(GENERATED)
- go install $(BUILD_FLAGS) -ldflags '$(LDFLAGS)' -tags '$(TAGS)'
- cp '$(GOPATH)/bin/gitote' .
- build-dev: $(GENERATED) govet
- go install $(BUILD_FLAGS) -tags '$(TAGS)'
- cp '$(GOPATH)/bin/gitote' .
- build-dev-race: $(GENERATED) govet
- go install $(BUILD_FLAGS) -race -tags '$(TAGS)'
- cp '$(GOPATH)/bin/gitote' .
- bindata: pkg/bindata/bindata.go
- pkg/bindata/bindata.go: $(DATA_FILES)
- ./go-bindata -o=$@ -ignore="\\.DS_Store|README.md|TRANSLATORS|auth.d" -pkg=bindata conf/...
- less: public/css/gitote.min.css
- public/css/gitote.min.css: $(LESS_FILES)
- @type lessc >/dev/null 2>&1 && lessc -x $< >$@ || echo "lessc command not found, skipped."
- clean:
- go clean -i ./...
- clean-mac: clean
- find . -name ".DS_Store" -print0 | xargs -0 rm
- test:
- go test -cover -race ./...
- alpha:
- grep -rnw "WIP - Alpha" templates
- beta:
- grep -rnw "WIP - Beta" templates
- todo:
- grep -rnw "WIP - ToDo" templates
|