From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 5CF0F138334 for ; Thu, 4 Jul 2019 21:13:23 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 3A768E0878; Thu, 4 Jul 2019 21:13:16 +0000 (UTC) Received: from km35626.keymachine.de (text-idiomas.com [87.118.86.27]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id AB670E086E for ; Thu, 4 Jul 2019 21:13:14 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by km35626.keymachine.de (Postfix) with ESMTP id 6254D112460D for ; Thu, 4 Jul 2019 23:13:13 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at km35626.keymachine.de. Received: from km35626.keymachine.de ([127.0.0.1]) by localhost (km35626.keymachine.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id ZLr6weeFhxQ3 for ; Thu, 4 Jul 2019 23:13:11 +0200 (CEST) Received: from grusum.endjinn.de (92-166-142-46.pool.kielnet.net [46.142.166.92]) by km35626.keymachine.de (Postfix) with ESMTPSA id 2DDFD11245FE for ; Thu, 4 Jul 2019 23:13:11 +0200 (CEST) Received: by grusum.endjinn.de (Postfix, from userid 500) id A4FE41701EE; Thu, 4 Jul 2019 23:12:34 +0200 (CEST) Date: Thu, 4 Jul 2019 23:13:00 +0200 From: David Haller To: gentoo-user@lists.gentoo.org Subject: Re: [gentoo-user] How do I get rid of colors (console and xterm)? Message-ID: <20190704211300.tz5y42fezme63pgd@grusum.endjinn.de> Mail-Followup-To: gentoo-user@lists.gentoo.org References: <87bly938vs.fsf@ra.horus-it.com> <2ae342a8-e7af-439b-2de0-4e3f67d1a43a@groessler.org> Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-user@lists.gentoo.org Reply-to: gentoo-user@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-15 Content-Disposition: inline In-Reply-To: <2ae342a8-e7af-439b-2de0-4e3f67d1a43a@groessler.org> Organization: Nah, not today! X-Clacks-Overhead: GNU Terry Pratchett User-Agent: NeoMutt/20170609 (1.8.3) X-Archives-Salt: a88a69a7-68cf-4f4e-9d47-ec93a0e2f292 X-Archives-Hash: 49c64dfcde619639824752bb252aadf2 Hello, On Thu, 04 Jul 2019, Christian Groessler wrote: >On 7/4/19 9:19 PM, Ralph Seichter wrote: >> * Christian Groessler: >> > My question is how do I get rid of colors in "emerge", "man" and other >> > command line programs. >> The methods vary between command line tools. You can for example >> disable the 'manpager' USE flag for sys-apps/man-db. The manual page for >> emerge mentions different methods (search for "--color"). Depending on >> the terminal software you use, you might be able to select monochromatic >> colour profiles (iterm2 for macOS does support this). > >In the meanwhile I had found out the "NOCOLORS" setting in make.conf which >works for "emerge". Your term looks rather low contrast with that rather bright dark greenish background... I use 'grey5' ;) You can also adjust the colours see 'man 5 color.map' and /etc/portage/color.map. And/or even patch emerge's output routines (I think there's some stuff that has no variable in color.map, and which is hard to read on grey5). I use this: ==== /etc/portage/patches/sys-apps/portage/portage_output_colors-2.3.44.patch ==== diff -x '*~' -purN a/lib/portage/output.py b/lib/portage/output.py --- a/lib/portage/output.py 2017-12-16 01:48:01.000000000 +0100 +++ b/lib/portage/output.py 2017-12-16 05:54:28.701929379 +0100 @@ -100,8 +115,8 @@ codes["darkgreen"] = codes["0x00AA00"] codes["yellow"] = codes["0xFFFF55"] codes["brown"] = codes["0xAA5500"] -codes["blue"] = codes["0x5555FF"] -codes["darkblue"] = codes["0x0000AA"] +codes["blue"] = esc_seq + "36;1m" # codes["0x5555FF"] +codes["darkblue"] = esc_seq + "36m" # codes["0x0000AA"] codes["fuchsia"] = codes["0xFF55FF"] codes["purple"] = codes["0xAA00AA"] ==== >man pages in color are the other most important problem right now. I will >check out your suggestion. AFAIK that mostly depends on what you use as pager for man, e.g. less. ==== Controlling formatted output -P pager, --pager=pager Specify which output pager to use. By default, man uses less -s. This option overrides the $MANPAGER environment variable, which in turn overrides the $PAGER environment variable. It is not used in conjunction with -f or -k. ==== So, have a look at the MANPAGER and PAGER variables if they're set. If they are, have a look at the config of that pager, else at that of 'less(1)'. Oh, and have a look at your terminal options. E.g. use 'xterm -cm' instead of 'xterm'... (or set the according Xresource) and all you get is black & white ;) HTH, -dnh -- # Mmm, yesssss. cookies my preciousssss! Mmm, yes downloads it # is! We mustn't have nasty little gmakeses deleting our # precious cookieses now must we? -- gar.lib.mk of 'konstruct'