Commit 91ee7786 by Iwasaki Yudai

Show commit ID on version

1 parent 4fd3ac37
Showing with 6 additions and 4 deletions
OUTPUT_DIR = ./builds
GIT_COMMIT = `git rev-parse HEAD`
GIT_COMMIT = `git rev-parse HEAD | cut -c1-10`
BUILD_OPTIONS = -ldflags "-X main.CommitID=$(GIT_COMMIT)"
gotty: server/asset.go main.go server/*.go webtty/*.go backend/*.go
godep go build
gotty: server/asset.go main.go server/*.go webtty/*.go backend/*.go Makefile
godep go build ${BUILD_OPTIONS}
asset: server/asset.go
......
......@@ -18,7 +18,7 @@ import (
func main() {
app := cli.NewApp()
app.Name = "gotty"
app.Version = Version
app.Version = Version + "+" + CommitID
app.Usage = "Share your terminal as a web application"
app.HideHelp = true
cli.AppHelpTemplate = helpTemplate
......
package main
var Version = "2.0.0-alpha"
var CommitID = "unknown_commit"
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!