You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

12 lines
289 B

#!/bin/sh
#
# NOTE: use with user cron, eg)
# 0 */2 * * * $HOME/bin/pacman_notify.sh
PKGS=$(checkupdates)
uid=1000
export DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/$uid/bus
if [ $(echo "$PKGS" | wc -w) -gt 0 ]; then
notify-send "$(echo "$PKGS" | wc -l) updates available" "$PKGS"
fi