diff options
author | Allan McRae <allan@archlinux.org> | 2012-01-20 14:25:57 +0100 |
---|---|---|
committer | Dan McGee <dan@archlinux.org> | 2012-01-23 16:23:21 +0100 |
commit | edd4276bbf3d21a7353e3d67ce6639246ef8032d (patch) | |
tree | a2b42d5b0c489d3ec5145907373b91ae51143962 /scripts | |
parent | df47136bcfd3fdec150fc8613f3fe243432d875f (diff) | |
download | pacman-edd4276bbf3d21a7353e3d67ce6639246ef8032d.tar.gz pacman-edd4276bbf3d21a7353e3d67ce6639246ef8032d.tar.xz |
makepkg: restrict usage of flags passed to pacman
With pacman-4.0, using --noconfirm or --noprogressbar with -Q or -T
results in pacman reporting an "invalid option" error. Restrict the
passing of these options to pacman. Fixes FS#28012.
Signed-off-by: Allan McRae <allan@archlinux.org>
Signed-off-by: Dan McGee <dan@archlinux.org>
Diffstat (limited to 'scripts')
-rw-r--r-- | scripts/makepkg.sh.in | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/scripts/makepkg.sh.in b/scripts/makepkg.sh.in index 81e77e47..89045ac9 100644 --- a/scripts/makepkg.sh.in +++ b/scripts/makepkg.sh.in @@ -412,7 +412,11 @@ download_file() { run_pacman() { local cmd - printf -v cmd "%q " "$PACMAN" $PACMAN_OPTS "$@" + if [[ ! $1 = -@(T|Qq) ]]; then + printf -v cmd "%q " "$PACMAN" $PACMAN_OPTS "$@" + else + printf -v cmd "%q " "$PACMAN" "$@" + fi if (( ! ASROOT )) && [[ ! $1 = -@(T|Qq) ]]; then if type -p sudo >/dev/null; then cmd="sudo $cmd" |