|
|
|
@ -1,9 +1,9 @@
|
|
|
|
|
LDFLAGS += -X "github.com/gogits/gogs/modules/setting.BuildTime=$(shell date -u '+%Y-%m-%d %I:%M:%S %Z')"
|
|
|
|
|
LDFLAGS += -X "github.com/gogits/gogs/modules/setting.BuildGitHash=$(shell git rev-parse HEAD)"
|
|
|
|
|
LDFLAGS += -X "github.com/gogits/gogs/pkg/setting.BuildTime=$(shell date -u '+%Y-%m-%d %I:%M:%S %Z')"
|
|
|
|
|
LDFLAGS += -X "github.com/gogits/gogs/pkg/setting.BuildGitHash=$(shell git rev-parse HEAD)"
|
|
|
|
|
|
|
|
|
|
DATA_FILES := $(shell find conf | sed 's/ /\\ /g')
|
|
|
|
|
LESS_FILES := $(wildcard public/less/gogs.less public/less/_*.less)
|
|
|
|
|
GENERATED := modules/bindata/bindata.go public/css/gogs.css
|
|
|
|
|
GENERATED := pkg/bindata/bindata.go public/css/gogs.css
|
|
|
|
|
|
|
|
|
|
OS := $(shell uname)
|
|
|
|
|
|
|
|
|
@ -27,7 +27,7 @@ dist: release
|
|
|
|
|
|
|
|
|
|
govet: |
|
|
|
|
$(GOVET) gogs.go
|
|
|
|
|
$(GOVET) models modules routers
|
|
|
|
|
$(GOVET) models pkg routers
|
|
|
|
|
|
|
|
|
|
build: $(GENERATED) |
|
|
|
|
go install $(BUILD_FLAGS) -ldflags '$(LDFLAGS)' -tags '$(TAGS)'
|
|
|
|
@ -50,9 +50,9 @@ pack:
|
|
|
|
|
|
|
|
|
|
release: build pack |
|
|
|
|
|
|
|
|
|
bindata: modules/bindata/bindata.go |
|
|
|
|
bindata: pkg/bindata/bindata.go |
|
|
|
|
|
|
|
|
|
modules/bindata/bindata.go: $(DATA_FILES) |
|
|
|
|
pkg/bindata/bindata.go: $(DATA_FILES) |
|
|
|
|
go-bindata -o=$@ -ignore="\\.DS_Store|README.md|TRANSLATORS" -pkg=bindata conf/...
|
|
|
|
|
|
|
|
|
|
less: public/css/gogs.css |
|
|
|
@ -70,11 +70,11 @@ test:
|
|
|
|
|
go test -cover -race ./...
|
|
|
|
|
|
|
|
|
|
fixme: |
|
|
|
|
grep -rnw "FIXME" cmd routers models modules
|
|
|
|
|
grep -rnw "FIXME" cmd routers models pkg
|
|
|
|
|
|
|
|
|
|
todo: |
|
|
|
|
grep -rnw "TODO" cmd routers models modules
|
|
|
|
|
grep -rnw "TODO" cmd routers models pkg
|
|
|
|
|
|
|
|
|
|
# Legacy code should be remove by the time of release
|
|
|
|
|
legacy: |
|
|
|
|
grep -rnw "LEGACY" cmd routers models modules
|
|
|
|
|
grep -rnw "LEGACY" cmd routers models pkg
|
|
|
|
|