:: Re: [DNG] tool to check for updates…
Pàgina inicial
Delete this message
Reply to this message
Autor: KatolaZ
Data:  
A: dng
Assumpte: Re: [DNG] tool to check for updates without root??
On Wed, Jun 22, 2016 at 02:15:17AM +0200, emninger@??? wrote:
> May someone of you knows if their exists in the .deb world a tool which
> checks for available updates and which does not need root.
>
> What i am looking for, is just a simple "update available" notifier
> (with other package managers that's possible, but i do not see a way to
> do that with apt or aptitude).
>


The easiest way is to have a cron script that runs once a day, with
root provileges, and calls "apt-get update". Then, your notifier could
be as simple as:

apt-get -s upgrade | grep "^[0-9]* upgr" | cut -d " " -f 1

which will give the number of packages that would be upgraded, and
does not require root. But remember: the check should be performed
only once every "apt-get update", because the result does not change
if you don't update the list of available packages.

HND

KatolaZ

-- 
[ ~.,_  Enzo Nicosia aka KatolaZ - GLUGCT -- Freaknet Medialab  ]  
[     "+.  katolaz [at] freaknet.org --- katolaz [at] yahoo.it  ]
[       @)   http://kalos.mine.nu ---  Devuan GNU + Linux User  ]
[     @@)  http://maths.qmul.ac.uk/~vnicosia --  GPG: 0B5F062F  ] 
[ (@@@)  Twitter: @KatolaZ - skype: katolaz -- github: KatolaZ  ]