From bc3fe00be4d8a5c1656deac03fb151c4cadb26eb Mon Sep 17 00:00:00 2001 From: Pierce Lopez Date: Mon, 27 Mar 2017 14:35:28 -0400 Subject: [PATCH] dist.sh: add .exe for windows build --- dist.sh | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/dist.sh b/dist.sh index 4d58ebf..3bc45ba 100755 --- a/dist.sh +++ b/dist.sh @@ -20,9 +20,13 @@ echo "... running tests" for os in windows linux darwin; do echo "... building v$version for $os/$arch" + EXT= + if [ $os = windows ]; then + EXT=".exe" + fi BUILD=$(mktemp -d ${TMPDIR:-/tmp}/oauth2_proxy.XXXXXX) TARGET="oauth2_proxy-$version.$os-$arch.$goversion" - GOOS=$os GOARCH=$arch CGO_ENABLED=0 go build -o $BUILD/$TARGET/oauth2_proxy || exit 1 + GOOS=$os GOARCH=$arch CGO_ENABLED=0 go build -o $BUILD/$TARGET/oauth2_proxy$EXT || exit 1 pushd $BUILD tar czvf $TARGET.tar.gz $TARGET mv $TARGET.tar.gz $DIR/dist