Artix update without redbutton
You can do it according to the artix installation as follows:
sudo -i
pacman -Sy pacman-contrib artix-archlinux-support
sed -i 's/#ParallelDownloads = 5/ParallelDownloads = 5/' /etc/pacman.conf
sed -i '$a \\n[universe] \n Server = https://universe.artixlinux.org/$arch' /etc/pacman.conf
sed -i '$a \\n[omniverse] \n Server = http://omniverse.artixlinux.org/$arch' /etc/pacman.conf
sed -i '$a \\n # Arch \n[extra] \n Include = /etc/pacman.d/mirrorlist-arch' /etc/pacman.conf
sed -i '$a \\n[community] \n Include = /etc/pacman.d/mirrorlist-arch' /etc/pacman.conf
cp /etc/pacman.d/mirrorlist /etc/pacman.d/mirrorlist.pacnew
cp /etc/pacman.d/mirrorlist-arch /etc/pacman.d/mirrorlist-arch.pacnew
sed -i 's/#Server/Server/' /etc/pacman.d/mirrorlist-arch.pacnew
cat <<EOF >> /usr/bin/update-mirrors
#!/bin/bash
rankmirrors -v -n 10 /etc/pacman.d/mirrorlist.pacnew | tee /etc/pacman.d/mirrorlist &&
rankmirrors -v -n 10 /etc/pacman.d/mirrorlist-arch.pacnew | tee /etc/pacman.d/mirrorlist-arch
EOF
chmod +x /usr/bin/update-mirrors
cat <<EOF >> /usr/bin/update-artix
#!/bin/bash
pacman -Sc --noconfirm &&
pacman -Syu --noconfirm
EOF
chmod +x /usr/bin/update-artix
exit
Quick guide:
sudo update-mirrors
sudo update-artix
Lines for conky or whatever;
Last update Date:
awk '/pacman -Syu --noconfirm/' /var/log/pacman.log | tail -1l | cut -b 4-11
Last update Time:
awk '/pacman -Syu --noconfirm/' /var/log/pacman.log | tail -1l | cut -b 13-20
New packages:
checkupdates | wc -l