Skip to content
This repository has been archived by the owner on Jan 17, 2018. It is now read-only.

Commit

Permalink
Merge pull request #58 from ahmetalpbalkan/version-info
Browse files Browse the repository at this point in the history
Get version info automatically from git env
  • Loading branch information
ahmetb authored Aug 20, 2016
2 parents ea32692 + 6ba465b commit b72188a
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 3 deletions.
5 changes: 3 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,13 @@ install:
- export GO15VENDOREXPERIMENT=1
before_script:
- go get -u github.com/golang/lint/golint
go: 1.5
- go get -u github.com/ahmetalpbalkan/govvv
go: 1.7
script:
- test -z "$(gofmt -s -l -w . | tee /dev/stderr)"
- test -z "$(golint . | tee /dev/stderr)"
- go vet .
- GOOS=linux GOARCH=amd64 go build -v -o bin/azurefile-dockervolumedriver .
- GOOS=linux GOARCH=amd64 govvv build -v -o bin/azurefile-dockervolumedriver .
- go list ./... | grep -v '/vendor/' | xargs go test -v
deploy:
provider: releases
Expand Down
9 changes: 8 additions & 1 deletion main.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,17 @@ const (
metadataRoot = "/etc/docker/plugins/azurefile/volumes"
)

var (
// GitSummary is provided at compile-time when built with govvv.
// If the source tree corresponds to a tag, the tag name is used.
// Otherwise, provides a string summarizing the state of git tree.
GitSummary string
)

func main() {
cmd := cli.NewApp()
cmd.Name = "azurefile-dockervolumedriver"
cmd.Version = "0.2.1"
cmd.Version = GitSummary
cmd.Usage = "Docker Volume Driver for Azure File Service"
cli.AppHelpTemplate = usageTemplate

Expand Down

0 comments on commit b72188a

Please sign in to comment.