Report a readable diagnostic on empty -J argument in CLI

This commit is contained in:
scaventz
2021-02-22 11:16:03 +08:00
committed by Alexander Udalov
parent 81a495b494
commit 9a7ef11043
3 changed files with 22 additions and 2 deletions
+4
View File
@@ -52,6 +52,10 @@ while [ $# -gt 0 ]; do
;;
-J*)
java_args=("${java_args[@]}" "${1:2}")
if [ "x${1:2}" = "x" ]; then
echo "error: empty -J argument"
exit 1
fi
shift
;;
*)