2

I have a system which is a mishmash of testing and unstable and some from experimental.

How can I get a list of which packages I've installed from experimental?

peje
  • 131
  • 5

3 Answers3

2

You can use aptitude search "~S~i~Aexperimental"

1

Answering my own question.

I came up with this solution:

aptitude -t experimental search -F '%p %?V %?v %?t' --disable-columns .|\
grep -v none| \
grep experimental| \
awk '{if( $2 == $3) print $1}'

The aptitude line gets me a list with "package name(%p)", "version if upgrade to experimental(%?V)", "installed version(%?v)" and "archives(%?t)".

Then filter away packages which are not installed.

And keep only packages which are available in experimental.

If installed and upgradable version are the same we have a winner.

peje
  • 131
  • 5
0

There might be an easy way to do that, but if there isn't this might work to get you close:

  • Get all package names and versions from dpkg --list
  • Comment out all sources but stable in your apt sources, and then apt-get update
  • Search for all the installed package in the dpkg list, if it isn't there that is one. else use --compare-versions to dpkg to see if you have is newer than what is returned from apt.

I hope for your sake there is a better way ;-)

Kyle Brandt
  • 82,107
  • 71
  • 302
  • 444