git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: Eric Sunshine <sunshine@sunshineco.com>
To: Han-Wen Nienhuys <hanwen@google.com>
Cc: Junio C Hamano <gitster@pobox.com>,
	Jonathan Nieder <jrn@google.com>, Git List <git@vger.kernel.org>
Subject: Re: [PATCH v6 1/1] sideband: highlight keywords in remote sideband output
Date: Mon, 6 Aug 2018 14:58:28 -0400	[thread overview]
Message-ID: <CAPig+cScb_7s4a_ZSVCsr+nBxAHGHZVMZOtnrOgbhZUi96-VFA@mail.gmail.com> (raw)
In-Reply-To: <20180806174459.199589-2-hanwen@google.com>

On Mon, Aug 6, 2018 at 1:45 PM Han-Wen Nienhuys <hanwen@google.com> wrote:
> The colorization is controlled with the config setting "color.remote".
> [...]
> Helped-by: Duy Nguyen <pclouds@gmail.com>
> Signed-off-by: Han-Wen Nienhuys <hanwen@google.com>
> ---
> diff --git a/Documentation/config.txt b/Documentation/config.txt
> @@ -1263,6 +1263,18 @@ color.push::
> +color.remote::
> +       If set, keywords at the start of the line are highlighted. The
> +       keywords are "error", "warning", "hint" and "success", and are
> +       matched case-insensitively. Maybe set to `always`, `false` (or

s/Maybe/May be/

> +       `never`) or `auto` (or `true`). If unset, then the value of
> +       `color.ui` is used (`auto` by default).
> diff --git a/sideband.c b/sideband.c
> +static void maybe_colorize_sideband(struct strbuf *dest, const char *src, int n)
> +{
> +       if (!want_color_stderr(use_sideband_colors())) {
> +               strbuf_add(dest, src, n);
> +               fprintf(stderr, "added: '%s'\n", dest->buf);

Debugging gunk?

> +               return;
> +       }
> @@ -96,6 +204,7 @@ int recv_sideband(const char *me, int in_stream, int out)
>         if (outbuf.len) {
> +               fprintf(stderr, "last bit '%s'\n", outbuf.buf);

Debugging gunk?

>                 strbuf_addch(&outbuf, '\n');
>                 xwrite(2, outbuf.buf, outbuf.len);
>         }

      reply	other threads:[~2018-08-06 18:58 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-08-06 17:44 [PATCH v6 0/1] sideband: highlight keywords in remote sideband output Han-Wen Nienhuys
2018-08-06 17:44 ` [PATCH v6 1/1] " Han-Wen Nienhuys
2018-08-06 18:58   ` Eric Sunshine [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: http://vger.kernel.org/majordomo-info.html

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAPig+cScb_7s4a_ZSVCsr+nBxAHGHZVMZOtnrOgbhZUi96-VFA@mail.gmail.com \
    --to=sunshine@sunshineco.com \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=hanwen@google.com \
    --cc=jrn@google.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).