Created
March 3, 2018 07:38
-
-
Save Dobbie03/992635d4e6fcee82e184f363926d92c2 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
#Hugo F. | |
#Count how many update available using checkupdate | |
#echo "$(checkupdates|wc -l)+$(cower -u|wc -l)"|bc -l | |
COUNTARCH=$(checkupdates|wc -l) | |
COUNTAUR=$(cower -u|wc -l) | |
UPDATES=$(checkupdates | awk '{print $1;}') | |
TOTAL=$(($COUNTARCH+$COUNTAUR)) | |
if [[ $TOTAL -ge 1 ]]; then | |
echo $TOTAL | |
#notify-send -t 60 -u normal "New Arch Linux Updates" "$UPDATES" | |
fi | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment