2

As usual, every time I update I'm getting a list with which programs received an update. I also have a few PPA sources that are active.

I would like to know which update came from which source.

I'm using Mint, but I would prefer to do so from shell so this is relevant for all distributions using apt-get

1
  • apt-get -s upgrade would show you approximately where the packages are coming from. Commented Nov 3, 2015 at 22:48

1 Answer 1

1

This thread says you can run apt-cache policy <package name>. With this and aptitude -F%p --disable-columns search ~U from here, you can easily put together a small shell script to check and print for each package that will be upgraded,

aptitude -F%p --disable-columns search ~U | xargs apt-cache policy

Works perfectly for me on Trisquel, if you add that to your ~/.bashrc as an alias, for example

alias apt-wat='aptitude -F%p --disable-columns search ~U | xargs apt-cache policy'

You've got a bretty cewl command, shame it prints way too much.

or if you want to see where each package you have installed came from with dpkg -l, something like

dpkg -l | awk '{print $2}' | xargs apt-cache policy

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.