Browse Source

Remove build date from binary

renovate/src.techknowlogick.com-xormigrate-1.x
kolaente 5 months ago
parent
commit
021e3e307b
Signed by untrusted user: konrad GPG Key ID: F40E70337AB24C9B
4 changed files with 2 additions and 6 deletions
  1. +1
    -1
      Makefile
  2. +0
    -1
      pkg/cmd/version.go
  3. +1
    -1
      pkg/cmd/web.go
  4. +0
    -3
      pkg/version/version.go

+ 1
- 1
Makefile View File

@ -19,7 +19,7 @@ GOFMT ?= gofmt -s
GOFLAGS := -v -mod=vendor
EXTRA_GOFLAGS ?=
LDFLAGS := -X "code.vikunja.io/api/pkg/version.Version=$(shell git describe --tags --always --abbrev=10 | sed 's/-/+/' | sed 's/^v//' | sed 's/-g/-/')" -X "main.Tags=$(TAGS)" -X "code.vikunja.io/api/pkg/version.BuildTime=$(shell date -R)"
LDFLAGS := -X "code.vikunja.io/api/pkg/version.Version=$(shell git describe --tags --always --abbrev=10 | sed 's/-/+/' | sed 's/^v//' | sed 's/-g/-/')" -X "main.Tags=$(TAGS)"
PACKAGES ?= $(filter-out code.vikunja.io/api/pkg/integrations,$(shell go list -mod=vendor ./... | grep -v /vendor/))
SOURCES ?= $(shell find . -name "*.go" -type f)

+ 0
- 1
pkg/cmd/version.go View File

@ -31,6 +31,5 @@ var versionCmd = &cobra.Command{
Short: "Print the version number of Vikunja",
Run: func(cmd *cobra.Command, args []string) {
fmt.Printf("Vikunja api version %s\n", version.Version)
fmt.Printf("Built at %s\n", version.BuildTime)
},
}

+ 1
- 1
pkg/cmd/web.go View File

@ -42,7 +42,7 @@ var webCmd = &cobra.Command{
Run: func(cmd *cobra.Command, args []string) {
// Version notification
log.Infof("Vikunja version %s, built at %s", version.Version, version.BuildTime)
log.Infof("Vikunja version %s", version.Version)
// Additional swagger information
swagger.SwaggerInfo.Version = version.Version

+ 0
- 3
pkg/version/version.go View File

@ -21,6 +21,3 @@ package version
// Version sets the version to be printed to the user. Gets overwritten by "make release" or "make build" with last git commit or tag.
var Version = "0.7"
// BuildTime contains the build time of vikunja.
var BuildTime = ""

Loading…
Cancel
Save