mirror of
https://github.com/moparisthebest/pacman
synced 2025-03-01 01:41:52 -05:00
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>
This commit is contained in:
parent
df47136bcf
commit
edd4276bbf
@ -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"
|
||||
|
Loading…
x
Reference in New Issue
Block a user