From 6d7bf96c89bdcd9fe5bb30504e4817345f44ffac Mon Sep 17 00:00:00 2001 From: Natanael Copa Date: Fri, 27 May 2022 12:20:24 +0200 Subject: lbu: add test for lbu list usage --- lbu.in | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'lbu.in') diff --git a/lbu.in b/lbu.in index bff12a2..224f06b 100644 --- a/lbu.in +++ b/lbu.in @@ -380,11 +380,14 @@ usage_list() { usage: $PROGRAM list|ls __EOF__ - exit 1 + exit $1 } cmd_list() { cmd_migrate_include_exclude + if [ "$1" = "-h" ]; then + usage_list 0 + fi _gen_filelist } @@ -776,6 +779,9 @@ while getopts "adehlM:np:qrv" opt ; do ;; v) VERBOSE="$VERBOSE -v" ;; + '?') + usage_$SUBCMD "1" >&2 + ;; esac done shift $(expr $OPTIND - 1) -- cgit v1.2.3