Can aptitude show older versions of packages if available in /var/cache/apt/archives?

Dear Lazyweb,

is it possible to tell aptitude to show older versions of a package next to the currently available one if it is still present in /var/cache/apt/archives? Like it does when you use unstable and experimental side by side? I know that aptitude does not really support downgrades of packages, but showing those packages directly in aptitude if available in the cache is a lot easier than searching them in the file system and installing them manually, especially if you don’t know where they hide.

One thought on “Can aptitude show older versions of packages if available in /var/cache/apt/archives?

  1. Josh Triplett

    Not directly. However, you could make this work locally with a bit of configuration.

    First, add a file /etc/apt/apt.conf.d/99local-archives-apt-source containing the following:

    DPkg::Post-Invoke { “cd /var/cache/apt && /usr/bin/dpkg-scanpackages –multiversion archives | gzip -c > Packages.gz”; };

    Second, add a file /etc/apt/sources.list.d/local-archives.list containing the following:

    deb file:/var/cache/apt ./

    You’ll also need to manually run the command in the DPkg::Post-Invoke hook initially, as well as any time you clean up the apt cache; unfortunately, I don’t think any hook exists to catch the latter and handle it automatically.

    Reply

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>