Re: BUG #16108: Colorization to the output of command-line has unproperly behaviors at Windows platform
Michail Nikolaev <michail.nikolaev@gmail.com>
From: Michail Nikolaev <michail.nikolaev@gmail.com>
To: Juan José Santamaría Flecha <juanjo.santamaria@gmail.com>
Cc: Peter Eisentraut <peter.eisentraut@2ndquadrant.com>, "Tang, Haiying" <tanghy.fnst@cn.fujitsu.com>,
Thomas Munro <thomas.munro@gmail.com>, PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Date: 2020-02-22T20:08:45Z
Lists: pgsql-bugs, pgsql-hackers
Hello. > The patch about making color by default [1] introduces the function terminal_supports_color(), that I think is relevant for this issue. Please find attached a new version based on that idea. I am not sure it is good idea to mix both patches because it adds some confusion and makes it harder to merge each. Maybe is it better to update current patch the way to reuse some function later in [1]? Also, regarding comment > It is disabled by default, so it must be enabled to use color outpout. It is not true for new terminal, for example. Maybe it is better to rephrase it to something like: "Check if TV100 support if enabled and attempt to enable if not". [1] https://www.postgresql.org/message-id/flat/bbdcce43-bd2e-5599-641b-9b44b9e0add4@2ndquadrant.com
Commits
-
Fix command-line colorization on Windows with VT100-compatible environments
- 3b5709e664c4 12.3 landed
- 3b77dce863d9 13.0 landed