list of installed packages without using apt?
Am Montag, den 27.11.2017, 15:18 -0700 schrieb Stuart McGraw:
> Is there some way of getting output similar to 'apt list --
> without using apt?Â Â Specifically I want a list of installed packages,
> their version numbers, and whether they were installed at my request
> or as a dependency.Â Â dpkg-query provides the first two items and IÂ
> think apt-mark the last, but the problem is combining them.
> I dont want to use apt because: 1) I am using in a shell script andÂ
> apt prints an annoying warning, 2) The warning recommends againstÂ
> using apt in scripts :-)Â Â I want to use basic low-level commands
> and not large complex things like apt or aptitude.Â
the proper way would be:
dpkg -l | grep ^ii
installed debian packages store package info in /var/lib/dpkg/info/ ...
if you don't want to use dpkg-query or dpkg -l you could also do
something (slightly hackish) like:
ls /var/lib/dpkg/info/|grep .md5sums
to get the list of installed packages ...Â
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 181 bytes
Desc: This is a digitally signed message part