repositories
/
mbt-docker.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d291354
)
Improve build script options error reporting
author
Jérôme Benoit
<jerome.benoit@sap.com>
Mon, 17 Oct 2022 12:19:48 +0000
(14:19 +0200)
committer
Jérôme Benoit
<jerome.benoit@sap.com>
Mon, 17 Oct 2022 12:19:48 +0000
(14:19 +0200)
Signed-off-by: Jérôme Benoit <jerome.benoit@sap.com>
build-image.sh
patch
|
blob
|
blame
|
history
diff --git
a/build-image.sh
b/build-image.sh
index d18125af7b50d1c3adbd5d5625ef50919370af53..14efb6a7a0f0541ec4b6706e4c246c6cf0f2fd4d 100755
(executable)
--- a/
build-image.sh
+++ b/
build-image.sh
@@
-22,10
+22,20
@@
while getopts "n:h" option; do
elif [[ -z "${images##*$name*}" ]]; then
make NAME=${name}
else
+ echo "Error: Unknown image name for option argument -${OPTARG}" >&2;
usage
exit 1
fi
;;
+ \?)
+ # Invalid option
+ echo "Error: Unknown or invalid option argument for -${OPTARG}" >&2;
+ usage
+ exit 1;;
+ :)
+ echo "Error: Missing option argument for -${OPTARG}" >&2;
+ usage
+ exit 1;;
*|h)
usage
;;