Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I want to see a list of "New in repository" packages every time they appear after cache update. How can I achieve this?

Related questions:

How exactly does Synaptic and Aptitude keep track of "New in repository" packages?

Is there an RSS feed that alerts subscribers of new/updated packages in the official repositories?

share|improve this question
why not use Synaptic manager for the purpose :) – atenz Aug 8 '12 at 6:42
New as in updated? Brand new? – izx Aug 8 '12 at 6:50
I usually use apt-get update and I currenly see them only in Synaptic. But I want an automatic notification, not to check them manually. – int_ua Aug 8 '12 at 18:26

Set up an MTA on your system if you haven't already, so that emails sent from the command line will work.

Install the bsd-mailx package to give you a standard command mail to send emails to the MTA from the command line.

Write a script as follows:


mkdir -p ~/new-package-detector
cd ~/new-package-detector
apt-cache search .|awk '{print $1}'|sort|uniq > new-package-list
if [ -f old-package-list ]; then
    comm -23 new-package-list old-package-list > new-in-repository
    if [ -s new-in-repository ]; then
        mail -s 'New packages available' < new-in-repository
mv new-package-list old-package-list

Then set up a cron job to run your script regularly. You might need to add an apt-get update to the start of the script, too, in order to make sure that it happens before the check.

share|improve this answer
Isn't that info part of package info in cache? Does synaptic have its' own cache? – int_ua Feb 11 '13 at 8:49
I'm fairly sure (but not certain) that synaptic uses the system cache. But if you will rely on automation, then you won't always run synaptic directly, right? – Robie Basak Feb 11 '13 at 9:08
The point is I don't want to have another package cache if that info is already a part of apt/dpkg system. – int_ua Feb 11 '13 at 9:10
You won't. My script uses the system cache. The apt/dpkg system does not track "new" packages as such, just the archive package lists. So old-package-list has to be kept. But that file is not exactly big or any kind of burden, surely? – Robie Basak Feb 11 '13 at 9:19
creating a new file is not using a system cache. I consider it big as long as it's duplicating the info. But I'm still not sure if it is. That's another question, I'll add a link soon :) I've found the RSS. I'll award bounty to you, I appreciate your help, but I'll add my own answer to mark it correct. – int_ua Feb 11 '13 at 9:49

I think synaptic package manager already shows this information.

share|improve this answer
yes, but I don't run it very often. And it does not notify, just passively has them under one section. – int_ua Feb 11 '13 at 8:48
@int_ua yes :) This is now solved. – ZDroid Feb 11 '13 at 10:16
up vote 0 down vote accepted

I was just asking a wrong question. All I need is these RSS feeds:

Is there an RSS feed that alerts subscribers of new/updated packages in the official repositories?

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.