[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Suggestion to change text on faq page on searching for packages



On Thu, Mar 03, 2016 at 09:19:38PM -0800, Ian Kelling wrote:
> http://backports.debian.org/FAQ/
> The first suggested command for searching,
> dpkg -l  |awk '/^ii/ && $3 ~ /bpo[6-8]/ {print $2}'
> found 1/10 packages I had installed. The 2nd one found them all.
> I suggest removing the first one. At the very least, make it
> be the second suggestion instead of the first.

... ideally fix the command:
$ dpkg -l
is the same as
$ dpkg-query -l

both commands face the problem, that the version column has a fixed
width, which is obviously too short.

my suggestion:
$ dpkg-query -W | awk '$2 ~ /bpo[6-8]/ {print $1}'

(.. as it does not rely on aptitude)

Regards,
Matthias


Reply to: