updating Usage output and standardizing target variable

This commit is contained in:
Christer Edwards
2019-11-22 22:05:21 -07:00
parent c68efdfb3d
commit 72cbac6504

View File

@@ -31,7 +31,7 @@
. /usr/local/share/bastille/colors.pre.sh . /usr/local/share/bastille/colors.pre.sh
usage() { usage() {
echo -e "${COLOR_RED}Usage: bastille sysrc [ALL|glob] 'sysrc command'${COLOR_RESET}" echo -e "${COLOR_RED}Usage: bastille sysrc TARGET args${COLOR_RESET}"
exit 1 exit 1
} }
@@ -49,12 +49,12 @@ fi
TARGET="${1}" TARGET="${1}"
shift shift
if [ "$TARGET" = 'ALL' ]; then if [ "${TARGET}" = 'ALL' ]; then
JAILS=$(jls name) JAILS=$(jls name)
fi fi
if [ "$TARGET" != 'ALL' ]; then if [ "${TARGET}" != 'ALL' ]; then
JAILS=$(jls name | grep -w "${1}") JAILS=$(jls name | grep -w "${TARGET}")
fi fi
for _jail in ${JAILS}; do for _jail in ${JAILS}; do