summaryrefslogtreecommitdiff
path: root/lbu.in
diff options
context:
space:
mode:
authorNatanael Copa <ncopa@alpinelinux.org>2022-05-27 11:44:27 +0200
committerNatanael Copa <ncopa@alpinelinux.org>2022-06-28 18:23:25 +0200
commit8e83cad94a75c5915e26901011940ab1feeb1ef6 (patch)
treea2ea431fde04df03e1a6cd35f3b29b4b9f3d705f /lbu.in
parentbb867c57186f06ba172e7984b2318571ea08807b (diff)
downloadalpine-conf-8e83cad94a75c5915e26901011940ab1feeb1ef6.zip
lbu: add test for lbu include usage
Diffstat (limited to 'lbu.in')
-rw-r--r--lbu.in8
1 files changed, 4 insertions, 4 deletions
diff --git a/lbu.in b/lbu.in
index 6747ded..ee9c360 100644
--- a/lbu.in
+++ b/lbu.in
@@ -232,18 +232,18 @@ usage_include() {
-r Remove specified file(s) from include list instead of adding.
-v Verbose mode.
__EOF__
- exit 1
+ exit $1
}
cmd_include() {
cmd_migrate_include_exclude
if [ "$LIST" ] ; then
- [ $# -gt 0 ] && usage_include
+ [ $# -gt 0 ] && usage_include "1" >&2
show_include
return
fi
- [ $# -lt 1 ] && usage_include
+ [ $# -lt 1 ] && usage_include "1" >&2
if [ "$REMOVE" ] ; then
list_delete + "$@"
else
@@ -761,7 +761,7 @@ while getopts "adehlM:np:qrv" opt ; do
;;
e) [ -z "$ENCRYPTION" ] && ENCRYPTION="$DEFAULT_CIPHER"
;;
- h) usage_$SUBCMD
+ h) usage_$SUBCMD 0
;;
l) LIST="-l"
;;