|
|
@ -25,14 +25,14 @@ EXTRA_GOFLAGS ?= |
|
|
|
|
|
|
|
|
|
|
|
ifneq ($(DRONE_TAG),) |
|
|
|
ifneq ($(DRONE_TAG),) |
|
|
|
VERSION ?= $(subst v,,$(DRONE_TAG))
|
|
|
|
VERSION ?= $(subst v,,$(DRONE_TAG))
|
|
|
|
GITEA_VERSION := $(VERSION)
|
|
|
|
GITEA_VERSION ?= $(VERSION)
|
|
|
|
else |
|
|
|
else |
|
|
|
ifneq ($(DRONE_BRANCH),)
|
|
|
|
ifneq ($(DRONE_BRANCH),)
|
|
|
|
VERSION ?= $(subst release/v,,$(DRONE_BRANCH))
|
|
|
|
VERSION ?= $(subst release/v,,$(DRONE_BRANCH))
|
|
|
|
else
|
|
|
|
else
|
|
|
|
VERSION ?= master
|
|
|
|
VERSION ?= master
|
|
|
|
endif
|
|
|
|
endif
|
|
|
|
GITEA_VERSION := $(shell git describe --tags --always | sed 's/-/+/' | sed 's/^v//')
|
|
|
|
GITEA_VERSION ?= $(shell git describe --tags --always | sed 's/-/+/' | sed 's/^v//')
|
|
|
|
endif |
|
|
|
endif |
|
|
|
|
|
|
|
|
|
|
|
LDFLAGS := -X "main.Version=$(GITEA_VERSION)" -X "main.Tags=$(TAGS)"
|
|
|
|
LDFLAGS := -X "main.Version=$(GITEA_VERSION)" -X "main.Tags=$(TAGS)"
|
|
|
|