Skip to content

v3io/version-go

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Version

Go module to maintain an application version

Install

go get -u github.com/v3io/version-go

Usage

During build, add the following linker arguments to inject the version:

-ldflags="-X github.com/v3io/version-go/version.gitCommit=$(GIT_COMMIT) \
-X github.com/v3io/version-go/version.label=$(GIT_TAG)

In your application, you can then:

import "github.com/v3io/version-go"

// print the version
version.Get().String()

// use the version components
versionLabel := version.Get().Label

About

Go module to maintain an applicaiton version

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Contributors 3

  •  
  •  
  •  

Languages