Re: An introduction to Debian's topology/structure/???
On Fri 20 Jul 2018 at 07:07:34 (-0500), Richard Owlett wrote:
> On 07/19/2018 10:46 AM, Henrique de Moraes Holschuh wrote:
> >On Thu, 19 Jul 2018, David Wright wrote:
> >>While there are commands like aptitude search and aptitude why
> >>available for such purposes, these are really designed for routine
> >>maintenance. For your purposes, I think you need to develop a more
> >>intimate relationship with the files in /var/lib/apt/lists/,
> >
> >or look at the utilities that the package dctrl-tools provides ;-)
> >
>
> For my fellow newbies who come across this thread, the associated
> man pages are:
>
> https://manpages.debian.org/stretch/dctrl-tools/grep-dctrl.1.en.html
> grep-dctrl, grep-status, grep-available, grep-aptavail, grep-debtags
> https://manpages.debian.org/stretch/dctrl-tools/sort-dctrl.1.en.html
> https://manpages.debian.org/stretch/dctrl-tools/tbl-dctrl.1.en.html
> generate tabular representations of data in dctrl format
> https://manpages.debian.org/stretch/dctrl-tools/sync-available.8.en.html
> sync dpkg's available database with apt's database
>
> GREP-DCTRL(1) says in part, "Use your imagination! The building
> blocks are there ..."
>
> I believe it ;/ I suspect piping its output to tbl-dctrl will be
> interesting to say the least.
I'm not sure what tabulating it adds over a plain listing, unless
you intend it for documentation or publication.
But anyway, I found that defining a specific solution with
commands like these, combinations of commandline options etc.
was more difficult than a few lines of python once I had a
framework program that parsed the Debian control files into
suitable dictionaries.
Of course, this methodology is unsuitable for general release
unlike Debian's tools. But the skills one learns doing the work
onesself with shell and a programming language will be more
transferable to situations where Debian doesn't have a ready-built
tool. (eg the programs I use for smart editing of files en masse.)
BTW I'm slightly surprised you self-describe as a newbie.
You've been plugging away at Debian for years now and have
been reading voraciously in retirement.
Cheers,
David.
Reply to: