Add updates block to i3 bar
This commit is contained in:
parent
19906d627e
commit
cbc0c7b4c4
2 changed files with 25 additions and 1 deletions
19
i3/blocks/pacmanUpdates
Executable file
19
i3/blocks/pacmanUpdates
Executable file
|
@ -0,0 +1,19 @@
|
|||
#!/usr/bin/sh
|
||||
|
||||
if ! command -v checkupdates > /dev/null; then
|
||||
echo "You need to install checkupdates";
|
||||
echo "";
|
||||
echo "#FF0000"
|
||||
else
|
||||
count=$(checkupdates | wc -l)
|
||||
if [ "$count" = "0" ]; then
|
||||
count=""
|
||||
fi
|
||||
echo $count
|
||||
echo $count
|
||||
if [ "$count" -gt "5" ]; then
|
||||
echo "#FFOOOO"
|
||||
else
|
||||
echo "#FF8000"
|
||||
fi
|
||||
fi
|
Loading…
Add table
Add a link
Reference in a new issue