pg.ddx.io pgsql-hackers@postgresql.org mailing list archive
help / color / mirror / Atom feedFrom: Peter Eisentraut <peter.eisentraut@2ndquadrant.com>
To: Michael Paquier <michael@paquier.xyz>
Cc: Bruce Momjian <bruce@momjian.us>
Cc: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Juan José SantamarÃa Flecha <juanjo.santamaria@gmail.com>
Cc: Gavin Flower <GavinFlower@archidevsys.co.nz>
Cc: Robert Haas <robertmhaas@gmail.com>
Cc: pgsql-hackers <pgsql-hackers@postgresql.org>
Subject: Re: color by default
Date: Sun, 29 Mar 2020 11:56:15 +0200
Message-ID: <2fa9de54-68cd-b29f-1ed1-b6fea806039a@2ndquadrant.com> (raw)
In-Reply-To: <20200326063625.GG1471@paquier.xyz>
References: <20200106053824.GO3598@paquier.xyz>
<171d92f5-fc29-a207-3db9-c16c63bb2ea7@archidevsys.co.nz>
<CAC+AXB04-NC6vF=c63EDp1G+c8n4uciZjeKMHY29LkBmZTebHA@mail.gmail.com>
<20200303053101.GH32059@paquier.xyz>
<20200320021557.GC1850@momjian.us>
<20200321025522.GD10066@momjian.us>
<6707.1584760507@sss.pgh.pa.us>
<20200321032207.GE10066@momjian.us>
<20200323050410.GE2900@paquier.xyz>
<afc175cd-902b-3ee9-9cee-f709cadb9c23@2ndquadrant.com>
<20200326063625.GG1471@paquier.xyz>
On 2020-03-26 07:36, Michael Paquier wrote:
> I am not sure that deleting all the mentions would be a good idea, as
> we'd lose track of which tool supports coloring or not, and that could
> confuse users. What about switching the existing paragraph to a
> simple sentence with a link to the new appendix you are adding? Say:
> "pg_foo supports <place_your_link_here>colorized output</>".
I didn't do this because it would create additional complications in the
man pages. But there is now an index entry, so it's possible to find
more information.
>> + <para>
>> + The actual colors to be used are configured using the environment variable
>> + <envar>PG_COLORS</envar><indexterm><primary>PG_COLORS</primary></indexterm>
>> + (note plural). The value is a colon-separated list of
>> + <literal><replaceable>key</replaceable>=<replaceable>value</replaceable></literal>
>> + pairs. The keys specify what the color is to be used for. The values are
>> + SGR (Select Graphic Rendition) specifications, which are interpreted by the
>> + terminal.
>> + </para>
>
> A reference to SGR to understand better what's the list of values
> supported would be nice?
I'm not sure how to do that. The full list of possible values is huge,
and exactly what is supported depends on the terminal.
>> + <para>
>> + The default value is <literal>error=01;31:warning=01;35:locus=01</literal>.
>> + </para>
>
> Could it be possible to have more details about what those three
> fields map to?
I have added information about that and explained the example values. I
think if you search for "Select Graphic Rendition" and look for the
example values, you can make sense of this.
Committed with those changes. This closes the commit fest item.
--
Peter Eisentraut http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
view thread (34+ messages) latest in thread
Message-ID: <2fa9de54-68cd-b29f-1ed1-b6fea806039a@2ndquadrant.com>
Permalink: ../2fa9de54-68cd-b29f-1ed1-b6fea806039a@2ndquadrant.com/
Also on: postgresql.org/message-id/2fa9de54-68cd-b29f-1ed1-b6fea806039a@2ndquadrant.com
reply
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-hackers@postgresql.org
Cc: peter.eisentraut@2ndquadrant.com, michael@paquier.xyz, bruce@momjian.us, tgl@sss.pgh.pa.us, juanjo.santamaria@gmail.com, GavinFlower@archidevsys.co.nz, robertmhaas@gmail.com
Subject: Re: color by default
In-Reply-To: <2fa9de54-68cd-b29f-1ed1-b6fea806039a@2ndquadrant.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox