diff options
author | Dave Reisner <dreisner@archlinux.org> | 2014-10-19 22:06:31 +0200 |
---|---|---|
committer | Dave Reisner <dreisner@archlinux.org> | 2014-10-19 22:48:03 +0200 |
commit | bf7dc83bab4f002a29866fd30b1574b6fbca36aa (patch) | |
tree | aad5aee7fe5d0840df6109eb86c42555cd9e4933 /archbuild.in | |
parent | cae954ddb5d35877eaaea588b84f932863714568 (diff) | |
download | devtools-bf7dc83bab4f002a29866fd30b1574b6fbca36aa.tar.gz devtools-bf7dc83bab4f002a29866fd30b1574b6fbca36aa.tar.xz |
save and reuse original argv when auto-elevating
Fixes FS#42277.
Diffstat (limited to 'archbuild.in')
-rw-r--r-- | archbuild.in | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/archbuild.in b/archbuild.in index dc45c7f..9c5d706 100644 --- a/archbuild.in +++ b/archbuild.in @@ -29,6 +29,8 @@ usage() { exit 1 } +orig_argv=("$@") + while getopts 'hcr:' arg; do case "${arg}" in c) clean_first=true ;; @@ -37,11 +39,11 @@ while getopts 'hcr:' arg; do esac done +check_root "$0" "${orig_argv[@]}" + # Pass all arguments after -- right to makepkg makechrootpkg_args+=("${@:$OPTIND}") -check_root "$0" "$@" - if ${clean_first} || [[ ! -d "${chroots}/${repo}-${arch}" ]]; then msg "Creating chroot for [${repo}] (${arch})..." |