[ubuntu-uk] Comparing installed packages

Joe Alam yothsoggoth at gmail.com
Sun May 4 12:39:40 UTC 2014


There's probably a far better way that someone with some more experience
will suggest, but the first thing that came to mind is to write a little
program/script that does the following:

- read all the files, into their own list of packages
- combine the lists, filling a list of package names, sorted in
alphabetical order and removing duplicates
- iterate through the combined list, for each package check each of the
four individual lists and if it is in there output it, otherwise leave a

That should achieve it in a fairly simple way, and can be done with any

Best of luck,
On 4 May 2014 13:29, "Mark Fraser" <mfraz74+ubuntu at gmail.com> wrote:

> I've got 4 computers here that I would like to compare the installed
> packages
> on each one together. I've done dpkg --get-selection > installed.txt on
> each
> computer, but now I'm trying to merge each one into a single file and
> leave a
> space where a package isn't installed.
> Instead of:
> Acpi-support     acpi-support   Acpi-support            acpi-support
> adduser             acroread            adduser
> adduser
> Adobereader-enu acroread-bin    adobereader-enu adobereader-enu
> I'd like:
> Acpi-support     acpi-support   Acpi-support            acpi-support
>                                          acroread
>                                          acroread-bin
> adduser                                                         adduser
>                       adduser
> Adobereader-enu                                 adobereader-enu
> adobereader-enu
> Any ideas how to achieve this?
> --
> Registered Linux User #466407 http://counter.li.org
> --
> ubuntu-uk at lists.ubuntu.com
> https://lists.ubuntu.com/mailman/listinfo/ubuntu-uk
> https://wiki.ubuntu.com/UKTeam/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ubuntu.com/archives/ubuntu-uk/attachments/20140504/c6a46905/attachment.html>

More information about the ubuntu-uk mailing list