summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel M. Capella <polyzen@archlinux.org>2024-01-29 21:21:52 +0000
committerDaniel M. Capella <polyzen@archlinux.org>2024-01-29 21:21:52 +0000
commite10ba0285dac1e2751de691d821e51861ae955b7 (patch)
treea5f5425642660ec8b3b4ca8ae070d018062a6ae8
parent1fcd9b8b3980ebd75568aba8efb0ea37b68c0a56 (diff)
parentc33806a45fa09886efb45f52435c20343cc211db (diff)
Merge branch 'fix_checkupdates_dl_with_colors' into 'master'
Fix: Remove color code from the "updates" array when using the --download option Closes #124 See merge request pacman/pacman-contrib!44
-rw-r--r--src/checkupdates.sh.in3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/checkupdates.sh.in b/src/checkupdates.sh.in
index 9526e41..d8ac4cf 100644
--- a/src/checkupdates.sh.in
+++ b/src/checkupdates.sh.in
@@ -172,6 +172,9 @@ if (( ${#updates[@]} )); then
else
printf '%s\n' "${updates[@]}"
if (( DOWNLOAD_CACHE )); then
+ if (( PACMAN_COLOR )); then
+ updates=("${updates[@]#*m}")
+ fi
runcmd pacman -Sw --noconfirm "${updates[@]%% *}" --dbpath "$CHECKUPDATES_DB" --logfile /dev/null
fi
fi