Linux Lite Forums

Full Version: LL Software Update Notification..??
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hello More Knowledgeable Folks,

I found this whilst  "Googling", Is something like this feasible in LL.?
I just read the "[glow=green,2,300]Xfce & Update Notification[/glow]"

Software Update Notification

Dave
For some of the basic packaging operations, apt and yum are basically identical.
These are "similar" operations, but there are some differences in how they act.
These two are similar:
apt-get --simulate upgrade
yum check-update

I guess this one-liner can be used to display a notification if there are updates.
Code:
apt-get --simulate upgrade | grep "The following packages will be upgraded:"; if [ "${PIPESTATUS[1]}" -eq "0" ]; then notify-send -i /usr/share/icons/gnome/32x32/status/software-update-available.png -u normal Updates "There are updates available"; fi

Or in a script
Code:
#!/bin/bash
apt-get --simulate upgrade | grep "The following packages will be upgraded:"
 if [ "${PIPESTATUS[1]}" -eq "0" ]; then
      notify-send -i /usr/share/icons/gnome/32x32/status/software-update-available.png -u normal Updates "There are updates available."
 fi
The icon in the notification area is a tricky part.
Edit: This is not practical because you have to do sudo apt-get update first Smile
Damn you sudo! Smile
(11-19-2014, 08:37 PM)Jerry date Wrote: [ -> ]Damn you sudo! Smile


Code:
$ apt-cache policy sux
sux:
  Installed: (none)
  Candidate: (none)
  Version table:

;D
Hi,

Sorry some of that went over me..
So do I take it an automated check & notification is not possible then.??
the edit to message sudo requirement is stopping it.

Dave