Skip to content

Empty build details when using go install #1776

Open
@pboguslawski

Description

@pboguslawski

Describe the bug
When you build athens using go install, no version nor build time is set:

$ GOBIN=/tmp go install github.com/gomods/athens/cmd/proxy@latest
go: downloading github.com/gomods/athens v0.11.0
[...]

$ /tmp/proxy -version
Build Details:
	Version:	
	Date:	

Expected behavior

Version and build date are set automatically based on version selected by go install for installation and current time.

May help:
https://www.reddit.com/r/golang/comments/u1a7ah/how_to_embed_version_when_go_installing_since_you/

Environment (please complete the following information):

  • OS: Linux 64bit
  • Go version : 1.18
  • Proxy version : 0.11.0
  • Storage (fs/mongodb/s3 etc.) : any

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions