From 35b5600332d954f3398b605b05eea829173ff9e8 Mon Sep 17 00:00:00 2001 From: Patrick Lang Date: Wed, 19 Sep 2018 17:45:32 -0700 Subject: [PATCH] Adding parameter validation to build scripts --- build/build-all-containerized.sh | 5 +++++ build/build-all.sh | 5 +++++ 2 files changed, 10 insertions(+) diff --git a/build/build-all-containerized.sh b/build/build-all-containerized.sh index f0af145992..fec9ce94ff 100755 --- a/build/build-all-containerized.sh +++ b/build/build-all-containerized.sh @@ -1,4 +1,9 @@ #!/usr/bin/env bash +if [[ -z $1 ]] || [[ -z $2 ]]; then + echo "Usage: $0 " + echo " Example: $0 linux amd64" + exit 1 +fi BUILD_CONTAINER_NAME=acn-builder diff --git a/build/build-all.sh b/build/build-all.sh index eeb44e1ec2..97596cbe1d 100755 --- a/build/build-all.sh +++ b/build/build-all.sh @@ -1,2 +1,7 @@ #!/usr/bin/env bash +if [[ -z $1 ]] || [[ -z $2 ]]; then + echo "Usage: $0 " + echo " Example: $0 linux amd64" + exit 1 +fi GOOS=$1 GOARCH=$2 make all-binaries