From: Bruce Momjian <bruce@momjian.us>
To: Michael Paquier <michael@paquier.xyz>
Cc: Juan José Santamaría Flecha <juanjo.santamaria@gmail.com>
Cc: Gavin Flower <GavinFlower@archidevsys.co.nz>
Cc: Robert Haas <robertmhaas@gmail.com>
Cc: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Peter Eisentraut <peter.eisentraut@2ndquadrant.com>
Cc: pgsql-hackers <pgsql-hackers@postgresql.org>
Subject: Re: color by default
Date: Fri, 20 Mar 2020 22:55:22 -0400
Message-ID: <20200321025522.GD10066@momjian.us> (raw)
In-Reply-To: <20200320021557.GC1850@momjian.us>
References: <bbdcce43-bd2e-5599-641b-9b44b9e0add4@2ndquadrant.com>
<32117.1577799339@sss.pgh.pa.us>
<0e03c747-a48d-912e-325d-5051b593c332@archidevsys.co.nz>
<CA+TgmoYcSP=8bZRYkxmW-ZO4L_GL_ShFLf9HJk=r1DZsErq6ng@mail.gmail.com>
<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>
On Thu, Mar 19, 2020 at 10:15:57PM -0400, Bruce Momjian wrote:
> On Tue, Mar 3, 2020 at 02:31:01PM +0900, Michael Paquier wrote:
> > On Mon, Mar 02, 2020 at 01:00:44PM +0100, Juan José Santamaría Flecha wrote:
> > > - The new entry in the documentation, specially as the PG_COLORS parameter
> > > seems to be currently undocumented. The programs that can use PG_COLOR
> > > would benefit from getting a link to it.
> >
> > The actual problem here is that we don't have an actual centralized
> > place where we could put that stuff. And anything able to use this
> > option is basically anything using src/common/logging.c.
> >
> > Regarding PG_COLORS, the commit message of cc8d415 mentions it, but we
> > have no actual example of how to use it, and the original thread has
> > zero reference to it:
> > https://www.postgresql.org/message-id/6a609b43-4f57-7348-6480-bd022f924310@2ndquadrant.com
> >
> > And in fact, it took me a while to figure out that using it is a mix
> > of three keywords ("error", "warning" or "locus") separated by colons
> > which need to have an equal sign to the color defined. Here is for
> > example how to make the locus show up in yellow with errors in blue:
> > export PG_COLORS='error=01;34:locus=01;33'
> >
> > Having to dig into the code to find out that stuff is not a good user
> > experience. And I found out about that only because I worked on a
> > patch touching this area yesterday.
>
> I can confirm there is still no mention of PG_COLORS in our
> documentation.
My mistake, PG_COLOR (not PG_COLORS) is documented properly.
--
Bruce Momjian <bruce@momjian.us> https://momjian.us
EnterpriseDB https://enterprisedb.com
+ As you are, so once was I. As I am, so you will be. +
+ Ancient Roman grave inscription +
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: bruce@momjian.us, michael@paquier.xyz, juanjo.santamaria@gmail.com, GavinFlower@archidevsys.co.nz, robertmhaas@gmail.com, tgl@sss.pgh.pa.us, peter.eisentraut@2ndquadrant.com
Subject: Re: color by default
In-Reply-To: <20200321025522.GD10066@momjian.us>
* 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