clean: improve arg handling
- detect lack of options using actual arg count rather than first arg being an empty string. - fix string splitting issues by looping properly on "${@}" - tidier Gbp-Dch: Ignore
This commit is contained in:
parent
2d7ff4934d
commit
2d4b2c9e76
|
@ -39,17 +39,13 @@ fi
|
||||||
|
|
||||||
Remove_lockfile
|
Remove_lockfile
|
||||||
|
|
||||||
if [ -z "${1}" ]
|
if [ $# -eq 0 ]; then
|
||||||
then
|
set -- "--all"
|
||||||
ARGUMENTS="--all"
|
|
||||||
else
|
|
||||||
ARGUMENTS="${@}"
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
STAGEFILES_DIR="$(Stagefiles_dir)"
|
STAGEFILES_DIR="$(Stagefiles_dir)"
|
||||||
|
|
||||||
for ARGUMENT in ${ARGUMENTS}
|
for ARGUMENT in "${@}"; do
|
||||||
do
|
|
||||||
case "${ARGUMENT}" in
|
case "${ARGUMENT}" in
|
||||||
--all)
|
--all)
|
||||||
"${0}" noauto --chroot
|
"${0}" noauto --chroot
|
||||||
|
|
Loading…
Reference in New Issue