diff options
author | Jan Alexander Steffens (heftig) <jan.steffens@gmail.com> | 2017-03-07 19:27:36 +0100 |
---|---|---|
committer | Jan Alexander Steffens (heftig) <jan.steffens@gmail.com> | 2017-03-07 19:35:09 +0100 |
commit | 45f87aa9d5b44e4ff2f73be6597d4024bcded8e3 (patch) | |
tree | 70e691b68c47d7f794a096311ea7b102aa30228d /archbuild.in | |
parent | 66553e7e07af9261e55c7c287615b61dc080593d (diff) | |
download | devtools-45f87aa9d5b44e4ff2f73be6597d4024bcded8e3.tar.xz |
lib/archroot.sh: Simplify check_root
Move the function and save the orig_argv right along it.
Diffstat (limited to 'archbuild.in')
-rw-r--r-- | archbuild.in | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/archbuild.in b/archbuild.in index 9c5d706..4fb33c3 100644 --- a/archbuild.in +++ b/archbuild.in @@ -1,6 +1,7 @@ #!/bin/bash m4_include(lib/common.sh) +m4_include(lib/archroot.sh) base_packages=(base-devel) makechrootpkg_args=(-c -n) @@ -29,8 +30,6 @@ usage() { exit 1 } -orig_argv=("$@") - while getopts 'hcr:' arg; do case "${arg}" in c) clean_first=true ;; @@ -39,7 +38,7 @@ while getopts 'hcr:' arg; do esac done -check_root "$0" "${orig_argv[@]}" +check_root # Pass all arguments after -- right to makepkg makechrootpkg_args+=("${@:$OPTIND}") |