File tree Expand file tree Collapse file tree 3 files changed +33
-0
lines changed Expand file tree Collapse file tree 3 files changed +33
-0
lines changed Original file line number Diff line number Diff line change 55* .so
66* .dylib
77terrafile
8+ output
89
910# Test binary, build with `go test -c`
1011* .test
Original file line number Diff line number Diff line change 1+ release :
2+ ./scripts/binary-release.sh
Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+
3+ # clean up
4+ echo " -> running clean up...."
5+ rm -rf output/*
6+
7+ # install gox
8+ if ! which gox > /dev/null; then
9+ echo " -> installing gox..."
10+ go get -u github.com/mitchellh/gox
11+ fi
12+
13+ # build
14+ echo " -> building..."
15+ gox \
16+ -os=" linux" \
17+ -arch=" amd64" \
18+ -output " output/{{.OS}}_{{.Arch}}/terrafile" \
19+ .
20+
21+ # Zip and copy to the dist dir
22+ echo " "
23+ echo " Packaging..."
24+ for PLATFORM in $( find ./output -mindepth 1 -maxdepth 1 -type d) ; do
25+ OSARCH=$( basename ${PLATFORM} )
26+ echo " --> ${OSARCH} "
27+
28+ pushd $PLATFORM > /dev/null 2>&1
29+ zip ../terrafile_${OSARCH} .zip ./*
30+ done
You can’t perform that action at this time.
0 commit comments