git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
* [PATCH 0/1] Colorize some errors on stderr
@ 2018-02-16 12:25 Johannes Schindelin
  2018-02-16 12:25 ` [PATCH 1/1] Colorize push errors Johannes Schindelin
                   ` (3 more replies)
  0 siblings, 4 replies; 22+ messages in thread
From: Johannes Schindelin @ 2018-02-16 12:25 UTC (permalink / raw)
  To: git; +Cc: Junio C Hamano

This is an RFC because it tries to introduce a fundamental new color feature:
Coloring messages *on stderr*.

So far, pretty much everything in color.[ch] assumed that you want to color
only stuff on stdout.

However, in this case, a user (who became a contributor!) wanted some messages
that are printed to stderr and were missed by his colleagues to be colored.

The contribution comes via Pull Request from the Git for Windows project:

	https://github.com/git-for-windows/git/pull/1429

Now, what would be possible solutions for this?

- introduce `int fd` in `want_color()` (and callees) so that we can make
  a distinction whether we want to detect whether stdout or stderr is connected
  to a tty

- introduce a separate `want_color_stderr()` (we still would need to decide
  whether we want a config setting for this)

- not color stderr, ever

Also, I did not have too much time to dig into the question how to test this in
Git's test suite. Do we already have tests that generate fake server-side errors
onto which I could piggy-back a new test case?

Thoughts? Suggestions? Help?


Ryan Dammrose (1):
  Colorize push errors

 advice.c       | 42 +++++++++++++++++++++++++++++++++++++++--
 builtin/push.c | 38 +++++++++++++++++++++++++++++++++++++
 transport.c    | 59 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++-
 3 files changed, 136 insertions(+), 3 deletions(-)


base-commit: b2e45c695d09f6a31ce09347ae0a5d2cdfe9dd4e
Published-As: https://github.com/dscho/git/releases/tag/colorize-push-errors-v1
Fetch-It-Via: git fetch https://github.com/dscho/git colorize-push-errors-v1
-- 
2.16.1.windows.4


^ permalink raw reply	[flat|nested] 22+ messages in thread

end of thread, other threads:[~2018-04-21 10:10 UTC | newest]

Thread overview: 22+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-02-16 12:25 [PATCH 0/1] Colorize some errors on stderr Johannes Schindelin
2018-02-16 12:25 ` [PATCH 1/1] Colorize push errors Johannes Schindelin
2018-02-16 19:21 ` [PATCH 0/1] Colorize some errors on stderr Junio C Hamano
2018-04-06 11:21   ` Johannes Schindelin
2018-04-05 22:48 ` [PATCH v2 0/4] Colorize push errors Johannes Schindelin
2018-04-05 22:48   ` [PATCH v2 1/4] color: introduce support for colorizing stderr Johannes Schindelin
2018-04-05 22:48   ` [PATCH v2 2/4] push: colorize errors Johannes Schindelin
2018-04-05 23:37     ` Jacob Keller
2018-04-06 11:15       ` Johannes Schindelin
2018-04-05 22:48   ` [PATCH v2 3/4] Add a test to verify that push errors are colorful Johannes Schindelin
2018-04-06 10:50     ` Eric Sunshine
2018-04-06 12:13       ` Johannes Schindelin
2018-04-05 22:48   ` [PATCH v2 4/4] Document the new color.* settings to colorize push errors/hints Johannes Schindelin
2018-04-06 10:56     ` Eric Sunshine
2018-04-06 12:15       ` Johannes Schindelin
2018-04-07  6:55         ` Eric Sunshine
2018-04-21 10:09   ` [PATCH v3 0/4] Colorize push errors Johannes Schindelin
2018-04-21 10:09     ` [PATCH v3 1/4] color: introduce support for colorizing stderr Johannes Schindelin
2018-04-21 10:10     ` [PATCH v3 2/4] push: colorize errors Johannes Schindelin
2018-04-21 10:10     ` [PATCH v3 3/4] Add a test to verify that push errors are colorful Johannes Schindelin
2018-04-21 10:10     ` [PATCH v3 4/4] Document the new color.* settings to colorize push errors/hints Johannes Schindelin
2018-04-06 18:48 ` [PATCH 0/1] Colorize some errors on stderr Ævar Arnfjörð Bjarmason

Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).