dotfiles/.i3blocks/updates

18 lines
332 B
Plaintext
Raw Normal View History

#!/usr/bin/env bash
if [ -f /dev/shm/claws_offline ]
then
echo "<span foreground=\"#F2777A\">█</span>"
exit
fi
avail=$(checkupdates | wc -l)
2018-03-27 17:38:03 +02:00
aur=$(yaourt -Qua | grep 'aur/' | wc -l)
2018-03-27 17:38:03 +02:00
if [[ $(($avail + $aur)) -eq 0 ]]
then
echo "<span foreground=\"#99CC99\">█</span>"
else
2018-03-27 17:38:03 +02:00
echo "<span foreground=\"#FFCC66\">█</span>"
fi