From 06638fa4c14574f0f85ce48a1a19467282ea87e3 Mon Sep 17 00:00:00 2001 From: Xueshan Feng Date: Thu, 8 Aug 2019 11:49:56 -0700 Subject: [PATCH] Bailout when there is not enough input arguments Currently the code carries on even missing required arguments. --- run_in_docker.sh | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/run_in_docker.sh b/run_in_docker.sh index b3bdd49887..9397f1a71e 100755 --- a/run_in_docker.sh +++ b/run_in_docker.sh @@ -15,8 +15,9 @@ #!/bin/bash set -e -if [ $# -lt 3 ]; - then echo "Usage: run_in_docker.sh " +if [ $# -lt 3 ]; then + echo "Usage: run_in_docker.sh " + exit 1 fi dockerfile=$1