mirror of
https://git.launchpad.net/ubuntu-dev-tools
synced 2025-03-12 15:41:09 +00:00
mk-sbuild: Use a more maintainable OPTS list using a bash array
This commit is contained in:
parent
6bf3640e8f
commit
e193c30695
25
mk-sbuild
Executable file → Normal file
25
mk-sbuild
Executable file → Normal file
@ -103,7 +103,30 @@ function usage()
|
||||
if [ -z "$1" ]; then
|
||||
usage
|
||||
fi
|
||||
OPTS=`getopt -o 'h' --long "help,debug,skip-updates,skip-security,skip-proposed,skip-eatmydata,arch:,name:,source-template:,debootstrap-mirror:,debootstrap-include:,debootstrap-exclude:,debootstrap-opts:,debootstrap-proxy:,debootstrap-no-check-gpg,debootstrap-keyring:,personality:,distro:,vg:,type:,target:" -- "$@"`
|
||||
supported_options=(
|
||||
help
|
||||
debug
|
||||
skip-updates
|
||||
skip-security
|
||||
skip-proposed
|
||||
skip-eatmydata
|
||||
arch:
|
||||
name:
|
||||
source-template:
|
||||
debootstrap-mirror:
|
||||
debootstrap-include:
|
||||
debootstrap-exclude:
|
||||
debootstrap-opts:
|
||||
debootstrap-proxy:
|
||||
debootstrap-no-check-gpg
|
||||
debootstrap-keyring:
|
||||
personality:
|
||||
distro:
|
||||
vg:
|
||||
type:
|
||||
target:
|
||||
)
|
||||
OPTS=$(getopt -o 'h' --long "$(IFS=, && echo "${supported_options[*]}")" -- "$@")
|
||||
eval set -- "$OPTS"
|
||||
|
||||
VG=""
|
||||
|
Loading…
x
Reference in New Issue
Block a user