[Aptitude-devel] Display source alongside version
Daniel Burrows
dburrows at debian.org
Wed Jan 7 01:45:17 UTC 2009
On Tue, Jan 06, 2009 at 11:58:34AM +0100, Obey Arthur Liu <arthur at milliways.fr> was heard to say:
> It's been a pretty old request of mine, but I'd like very much to be
> able to display the source of a package with the version.
> Here are some examples :
>
> wine 1.0.1-1 (testing/main, unstable/main)
> wine 1.1.9-1 (experimental/main)
> wine 1.1.1~winehq0~debian~4.0-1 (winehq/etch)
>
> It seems that libapt doesn't offer facilities to get the kind of
> information needed right away. Is there a way around this ? Did I miss
> something ?
You can get the archive pretty easily from PkgFileIterator::Archive(),
as done in, e.g., archive_text() (which should move to src/generic/apt
but currently lives in src/solution_fragment.cc). Some other
meta-information, such as the component and the origin, is also
available in the same iterator.
Daniel
More information about the Aptitude-devel
mailing list