From 460fa5a90f9eb06bf5aa401ee4b9f981f8e95a6d Mon Sep 17 00:00:00 2001 From: tzmfreedom Date: Sat, 10 Dec 2016 19:47:43 +0900 Subject: [PATCH] Add build script --- build.sh | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100755 build.sh diff --git a/build.sh b/build.sh new file mode 100755 index 0000000..a12c2a4 --- /dev/null +++ b/build.sh @@ -0,0 +1,12 @@ +#!/bin/sh + +if [ $# != 1 ]; then + echo "Usage: $0 [binary name]" + exit 0 +fi + +GOOS=windows GOARCH=386 go build -o ./bin/$1-windows386.exe +GOOS=windows GOARCH=amd64 go build -o ./bin/$1-windows64.exe + +GOOS=darwin GOARCH=386 go build -o ./bin/$1-darwin386 +GOOS=darwin GOARCH=amd64 go build -o ./bin/$1-darwin64