replace /dev/null 2>&1 with &>

This commit is contained in:
Tobias Powalowski 2023-01-19 08:12:54 +01:00
parent 8e0b7decf2
commit 297d50a907
3 changed files with 4 additions and 4 deletions

View file

@ -26,5 +26,5 @@ fi
echo "${_PACKAGE}" >binary.txt echo "${_PACKAGE}" >binary.txt
#shellcheck disable=SC2086 #shellcheck disable=SC2086
for i in $(pacman -Ql ${_PACKAGE} | grep "/usr/bin/..*"$ | cut -d' ' -f2); do for i in $(pacman -Ql ${_PACKAGE} | grep "/usr/bin/..*"$ | cut -d' ' -f2); do
command -v "${i}" >/dev/null 2>&1 || echo "${i}" >>binary.txt command -v "${i}" &>/dev/null || echo "${i}" >>binary.txt
done done

View file

@ -39,11 +39,11 @@ _prepare_pacman() {
mkdir -p "${_DESTDIR}/var/lib/pacman" mkdir -p "${_DESTDIR}/var/lib/pacman"
fi fi
# pacman-key process itself # pacman-key process itself
while pgrep -x pacman-key > /dev/null 2>&1; do while pgrep -x pacman-key &>/dev/null; do
sleep 1 sleep 1
done done
# gpg finished in background # gpg finished in background
while pgrep -x gpg > /dev/null 2>&1; do while pgrep -x gpg &>/dev/null; do
sleep 1 sleep 1
done done
[[ -e /etc/systemd/system/pacman-init.service ]] && systemctl stop pacman-init.service [[ -e /etc/systemd/system/pacman-init.service ]] && systemctl stop pacman-init.service

View file

@ -84,7 +84,7 @@ _dotimeset() {
_dialog --yesno "Do you want to use UTC for your clock?\n\nIf you choose 'YES' UTC (recommended default) is used,\nwhich ensures daylightsaving is set automatically.\n\nIf you choose 'NO' Localtime is used, which means\nthe system will not change the time automatically.\nLocaltime is also prefered on dualboot machines,\nwhich also run Windows, because UTC may confuse it." 14 60 && _HARDWARECLOCK="UTC" _dialog --yesno "Do you want to use UTC for your clock?\n\nIf you choose 'YES' UTC (recommended default) is used,\nwhich ensures daylightsaving is set automatically.\n\nIf you choose 'NO' Localtime is used, which means\nthe system will not change the time automatically.\nLocaltime is also prefered on dualboot machines,\nwhich also run Windows, because UTC may confuse it." 14 60 && _HARDWARECLOCK="UTC"
_dohwclock _dohwclock
# check internet connection # check internet connection
if ping -c1 www.google.com >/dev/null 2>&1; then if ping -c1 www.google.com &>/dev/null; then
if _dialog --yesno \ if _dialog --yesno \
"Do you want to use the Network Time Protocol (NTP) for syncing your clock, by using the internet clock pool?" 6 60; then "Do you want to use the Network Time Protocol (NTP) for syncing your clock, by using the internet clock pool?" 6 60; then
_dialog --infobox "Syncing clock with NTP pool..." 3 45 _dialog --infobox "Syncing clock with NTP pool..." 3 45