Re: Understanding aptitude search patterns



On Tue, Oct 4, 2011 at 2:16 PM, Panayiotis Karabassis <panayk@xxxxxxxxx> wrote:
I still have much to learn about aptitude, but in case anyone is
interested, I made some sense from the source code, which seem to be
ingenious at times:

There are indeed two modes, but not what I thought. There is a "match
all versions" mode, which seems to be used by ?all-versions() and a
"match any version" which seems to be used by everything else. What the
latter returns (all versions or just the versions that matched), I do
not know.

The really clever part is how ?any-version() works. Matches happen
against a pool of package versions. So ?any-version creates a *new pool*
for each package version in the original pool. Then it concatenates the
matches together. That way it forces a package search to become a
version search. Think about it. Amazing. I am a better programmer for
finding this gem.

The documentation could be more detailed though.
I propose you sending a patch with that detailed documentation to
aptitude-devel@xxxxxxxxxxxxxxxxxxxxxxx (or like a wishlist in PTS)

Regards,


--
To UNSUBSCRIBE, email to debian-user-REQUEST@xxxxxxxxxxxxxxxx
with a subject of "unsubscribe". Trouble? Contact listmaster@xxxxxxxxxxxxxxxx
Archive: http://lists.debian.org/CAL5yMZSLzJQdO5Y15R9OtQL7a7R3=-rjFE8vkBHYN1iJWPzMdQ@xxxxxxxxxxxxxx



Relevant Pages

  • Re: Understanding aptitude search patterns
    ... So ?any-version creates a *new pool* ... for each package version in the original pool. ... I propose you sending a patch with that detailed documentation to ... To UNSUBSCRIBE, email to debian-user-REQUEST@xxxxxxxxxxxxxxxx ...
    (Debian-User)
  • Re: Understanding aptitude search patterns
    ... So ?any-version creates a *new pool* ... for each package version in the original pool. ... That way it forces a package search to become a ... To UNSUBSCRIBE, email to debian-user-REQUEST@xxxxxxxxxxxxxxxx ...
    (Debian-User)
  • Re: Etch and openoffice: how to downgrade
    ... I was not able to download the package from there. ... deb-src http://snapshot.debian.net/archive pool openoffice.org ... To UNSUBSCRIBE, email to debian-user-REQUEST@xxxxxxxxxxxxxxxx ...
    (Debian-User)
  • Re: Where can I get a certain version of a package?
    ... > version of every package. ... Only every version that made it into a Debian release ... ... snapshot.debian.net has every version that was ever in the pool, ... To UNSUBSCRIBE, email to debian-user-request@lists.debian.org ...
    (Debian-User)
  • Re: Sources.list Question
    ... updating the package list. ... Repeat if you need to upgrade just that package, either by install it ... I need to upgrade Opendkim version 2.0.1 but squeeze repository remains ... To UNSUBSCRIBE, email to debian-user-REQUEST@xxxxxxxxxxxxxxxx ...
    (Debian-User)