Quantcast
Viewing all articles
Browse latest Browse all 3567

Beginners Questions • [O/S] Change color code for the word "[Installed]" when using apt search in the output?

Hello, welcome to the forums!
Is it possible to highlight the word "[Installed]" in the output of the terminal window when using <apt search>, using personalized color?
I don't think there is a way to tweak apt like that, at least to my knowledge.
However, you can do things like this:

Code:

$> apt --installed list "apt*"Listing... Doneapt-file/stable,now 3.3 all [installed]apt-forktracer/stable,now 0.9 all [installed]apt-listchanges/stable,now 3.24 all [installed]apt-rdepends/stable,now 1.3.0-10 all [installed]apt-utils/stable,now 2.6.1 amd64 [installed]apt/stable,now 2.6.1 amd64 [installed]aptitude-common/stable,now 0.8.13-5 all [installed,automatic]aptitude/stable,now 0.8.13-5 amd64 [installed]
Compare:

Code:

$> apt --installed list "*apt*"Listing... Doneapt-file/stable,now 3.3 all [installed]apt-forktracer/stable,now 0.9 all [installed]apt-listchanges/stable,now 3.24 all [installed]apt-rdepends/stable,now 1.3.0-10 all [installed]apt-utils/stable,now 2.6.1 amd64 [installed]apt/stable,now 2.6.1 amd64 [installed]aptitude-common/stable,now 0.8.13-5 all [installed,automatic]aptitude/stable,now 0.8.13-5 amd64 [installed]laptop-detect/stable,now 0.16 all [installed]libapt-pkg-perl/stable,now 0.1.40+b2 amd64 [installed,automatic]libapt-pkg6.0/stable,now 2.6.1 amd64 [installed,automatic]libfreeaptx0/stable,now 0.1.1-2 amd64 [installed,automatic]libraptor2-0/stable,now 2.0.15-4 amd64 [installed,automatic]python-apt-common/stable,now 2.6.0 all [installed,automatic]python3-apt/stable,now 2.6.0 amd64 [installed,automatic]
Note that this is not an exact equivalent of 'search' since by default 'search' also searches in other package fields (description in particular), not only package names.
Remember to always quote your arguments to protect them when using '*', for example "*apt*"

Statistics: Posted by fabien — 2024-02-08 11:42 — Replies 1 — Views 62



Viewing all articles
Browse latest Browse all 3567

Trending Articles