File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -36,10 +36,8 @@ install:
3636script :
3737 - make test
3838 - make -C client/ bootstrap build test
39- - mv client/deis client/deis-linux-amd64
40- - GOOS=darwin GOARCH=amd64 make -C client build
41- - mv client/deis client/deis-darwin-amd64
4239 - make -C docs/ build test
40+ before_deploy : make dist prep-bintray-json
4341deploy :
4442 - provider : script
4543 # ensure client/doc builds aren't removed
Original file line number Diff line number Diff line change 88 "name" : " 0.0.0"
99 },
1010 "files" : [
11- { "includePattern" : " client/deis-linux-amd64" , "uploadPattern" : " deis-linux-amd64" },
12- { "includePattern" : " client/deis-darwin-amd64" , "uploadPattern" : " deis-darwin-amd64" }
11+ {
12+ "includePattern" : " _dist/(.*)" ,
13+ "uploadPattern" : " $1"
14+ }
1315 ],
1416 "publish" : true
1517}
Original file line number Diff line number Diff line change @@ -7,13 +7,16 @@ DEV_ENV_IMAGE := quay.io/deis/go-dev:0.5.0
77DEV_ENV_WORK_DIR := /go/src/${repo_path}
88DEV_ENV_PREFIX := docker run --rm -e GO15VENDOREXPERIMENT=1 -e CGO_ENABLED=0 -v ${CURDIR}:${DEV_ENV_WORK_DIR} -w ${DEV_ENV_WORK_DIR}
99DEV_ENV_CMD := ${DEV_ENV_PREFIX} ${DEV_ENV_IMAGE}
10+ DIST_DIR := _dist
1011
1112GO_FILES = $(wildcard * .go)
1213GO_PACKAGES = cmd controller/api controller/client $(wildcard controller/models/* ) parser $(wildcard pkg/* )
1314GO_PACKAGES_REPO_PATH = $(addprefix $(repo_path ) /,$(GO_PACKAGES ) )
1415GOFMT = gofmt -e -l -s
1516GOTEST = go test --cover --race -v
1617
18+ VERSION := $(shell git describe --tags --abbrev=0 2>/dev/null) +$(shell git rev-parse --short HEAD)
19+
1720define check-static-binary
1821 if file $(1 ) | egrep -q "(statically linked|Mach-O)"; then \
1922 echo -n ""; \
@@ -33,9 +36,17 @@ build:
3336 ${DEV_ENV_CMD} make binary-build
3437 @$(call check-static-binary,deis)
3538
39+ build-all :
40+ gox -verbose \
41+ -os=" linux darwin " \
42+ -arch=" amd64 386" \
43+ -output=" $( DIST_DIR) /deis-${VERSION} -{{.OS}}-{{.Arch}}" .
44+
3645binary-build :
3746 go build -a -installsuffix cgo -ldflags ' -s' -o deis .
3847
48+ dist : build-all
49+
3950install :
4051 cp deis $$ GOPATH/bin
4152
You can’t perform that action at this time.
0 commit comments