Diff'ing different versions of the same debian package

Afaik the only way to do this is to get the source and make the diff's your self. You can get the actual source used for compiling the packages with apt-get. fx:

apt-get source gwibber=2.30.2-0ubuntu3 gwibber=2.30.0.1-0ubuntu1
diff -rupN gwibber-2.30.0.1/ gwibber-2.30.2/

This will print out all differences between all files in a standard patch format.


Here's another solution I hacked together: whatchanged.

It takes the name of the binary package you're interested in as the only argument. To use a recent SRU as an example:

./whatchanged python_papyon

This is what it does:

  1. Check if there's an update candidate; exit if there's none
  2. If a candidate exists, create temporary directories and fetch the source packages for both the installed version and the candidate into them
  3. Compare the two with debdiff and output to stdout (you'll probably want to redirect for easier reading)
  4. Clean up the temporary directories.

It probably needs to better handle certain things that may go wrong during source retrieval, the flow control is probably a bit off, and there must be more elegant ways for version checking, but it worked fine in my limited testing so far. For now, consider it a quick hack that works, and improvements are most welcome. I'll push it to a bzr repository and/or create a Launchpad project if it's useful to a few people.

Edit: Rather than let it rot on pastebin, I've started a Launchpad project for it; you can get the latest trunk revision with bzr branch lp:whatchanged. Feel free to report bugs, branch it, rewrite it in Perl, etc.


Here's one (probably not optimal) UDD way of doing it:

Pull -updates branch for your release (assuming Lucid) that (assumption follows) should contain the latest SRU:

bzr branch lp:ubuntu/lucid-updates/package_name

Get the changes introduced by the latest revision, which (assumption follows) should correspond to the latest SRU:

bzr diff -c`bzr revno`