Skip to content

Commit bd2ac67

Browse files
authored
preventing error message when invoking cromshell with no args (#52)
* preventing error message when invoking cromshell with no args fixes #51
1 parent 17aed47 commit bd2ac67

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

cromshell

+6-1
Original file line numberDiff line numberDiff line change
@@ -1199,7 +1199,12 @@ if ${ISINTERACTIVESHELL} ; then
11991199
# This is a good sub-command, so we do not need to do anything.
12001200
;;
12011201
*)
1202-
invalidSubCommand '' "sub-command" "${SUB_COMMAND}"
1202+
if [[ ${#SUB_COMMAND} -eq 0 ]]; then
1203+
simpleUsage
1204+
exit 0
1205+
else
1206+
invalidSubCommand '' "sub-command" "${SUB_COMMAND}"
1207+
fi
12031208
;;
12041209
esac
12051210

0 commit comments

Comments
 (0)