mirror of
https://github.com/moparisthebest/pacman
synced 2025-03-11 07:31:04 -04:00
makepkg: Turn PACMAN_OPTS into an array
Avoid potential word expansion with future inclusions Signed-off-by: Allan McRae <allan@archlinux.org>
This commit is contained in:
parent
1a29744d0d
commit
8ff03868a3
@ -87,7 +87,7 @@ SPLITPKG=0
|
|||||||
SOURCEONLY=0
|
SOURCEONLY=0
|
||||||
VERIFYSOURCE=0
|
VERIFYSOURCE=0
|
||||||
|
|
||||||
PACMAN_OPTS=
|
PACMAN_OPTS=()
|
||||||
|
|
||||||
shopt -s extglob
|
shopt -s extglob
|
||||||
|
|
||||||
@ -219,7 +219,7 @@ source_has_signatures() {
|
|||||||
run_pacman() {
|
run_pacman() {
|
||||||
local cmd
|
local cmd
|
||||||
if [[ $1 != -@(T|Qq) ]]; then
|
if [[ $1 != -@(T|Qq) ]]; then
|
||||||
cmd=("$PACMAN_PATH" $PACMAN_OPTS "$@")
|
cmd=("$PACMAN_PATH" "${PACMAN_OPTS[@]}" "$@")
|
||||||
else
|
else
|
||||||
cmd=("$PACMAN_PATH" "$@")
|
cmd=("$PACMAN_PATH" "$@")
|
||||||
fi
|
fi
|
||||||
@ -1780,8 +1780,8 @@ while true; do
|
|||||||
# Pacman Options
|
# Pacman Options
|
||||||
--asdeps) ASDEPS=1;;
|
--asdeps) ASDEPS=1;;
|
||||||
--needed) NEEDED=1;;
|
--needed) NEEDED=1;;
|
||||||
--noconfirm) PACMAN_OPTS+=" --noconfirm" ;;
|
--noconfirm) PACMAN_OPTS+=("--noconfirm") ;;
|
||||||
--noprogressbar) PACMAN_OPTS+=" --noprogressbar" ;;
|
--noprogressbar) PACMAN_OPTS+=("--noprogressbar") ;;
|
||||||
|
|
||||||
# Makepkg Options
|
# Makepkg Options
|
||||||
--allsource) SOURCEONLY=2 ;;
|
--allsource) SOURCEONLY=2 ;;
|
||||||
@ -1800,7 +1800,7 @@ while true; do
|
|||||||
-i|--install) INSTALL=1 ;;
|
-i|--install) INSTALL=1 ;;
|
||||||
--key) shift; GPGKEY=$1 ;;
|
--key) shift; GPGKEY=$1 ;;
|
||||||
-L|--log) LOGGING=1 ;;
|
-L|--log) LOGGING=1 ;;
|
||||||
-m|--nocolor) USE_COLOR='n'; PACMAN_OPTS+=" --color never" ;;
|
-m|--nocolor) USE_COLOR='n'; PACMAN_OPTS+=("--color never") ;;
|
||||||
--noarchive) NOARCHIVE=1 ;;
|
--noarchive) NOARCHIVE=1 ;;
|
||||||
--nocheck) RUN_CHECK='n' ;;
|
--nocheck) RUN_CHECK='n' ;;
|
||||||
--noprepare) RUN_PREPARE='n' ;;
|
--noprepare) RUN_PREPARE='n' ;;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user