-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
added version to main.go and a version file that can be bumped added a makefile for consistency removed the binaries directory
- Loading branch information
Nika Jones
committed
Jun 6, 2017
1 parent
3004a05
commit 3b9e727
Showing
6 changed files
with
37 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
0.1.0 |
Binary file not shown.
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
SHELL := /bin/bash | ||
BUILD_DATE = `date -u +"%a,|%d|%b|%Y|%T|%Z" | tr '|' ' '` | ||
BUILD_VERSION = `cat VERSION` | ||
|
||
default: mac | ||
|
||
mac: | ||
GOARCH=amd64 GOOS=darwin go build -o bin/osx/xcp -ldflags "-X \"main.binaryBuild=$(BUILD_DATE)\" -X main.binaryVersion=$(BUILD_VERSION)" | ||
|
||
win: | ||
GOARCH=amd64 GOOS=windows go build -o bin/win/xcp.exe -ldflags "-X \"main.binaryBuild=$(BUILD_DATE)\" -X \"main.binaryVersion=$(BUILD_VERSION)\"" | ||
|
||
lin: | ||
GOARCH=amd64 GOOS=linux go build -o bin/lin/xcp -ldflags "-X \"main.binaryBuild=$(BUILD_DATE)\" -X \"main.binaryVersion=$(BUILD_VERSION)\"" | ||
|
||
release: | ||
tar -czvf xcp-${BUILD_VERSION}-lin.tar.gz -C bin/lin/ xcp | ||
tar -czvf xcp-${BUILD_VERSION}-macos.tar.gz -C bin/osx xcp | ||
tar -czvf xcp-${BUILD_VERSION}-win.tar.gz -C bin/win xcp.exe | ||
mkdir -p releases/${BUILD_VERSION} && mv *.tar.gz releases/${BUILD_VERSION}/. | ||
|
||
all: mac win lin |