From: Junio C Hamano <gitster@pobox.com>
To: Taylor Blau <me@ttaylorr.com>
Cc: "Ævar Arnfjörð Bjarmason" <avarab@gmail.com>,
"Git ML" <git@vger.kernel.org>,
"Jonathan Tan" <jonathantanmy@google.com>
Subject: Re: BUG: Various "advice.*" config doesn't work
Date: Mon, 31 Jan 2022 09:46:32 -0800 [thread overview]
Message-ID: <xmqqv8xziyrr.fsf@gitster.g> (raw)
In-Reply-To: <YfgdsnfQ05ywre8l@nand.local> (Taylor Blau's message of "Mon, 31 Jan 2022 12:34:42 -0500")
Taylor Blau <me@ttaylorr.com> writes:
> What I'm more or less trying to point out is that an unguarded advise()
> function defeats the purpose of the advice API, which should exist to
> avoid mistakes like these (where advice is printed to the user when they
> have already opted out of that advice).
advise() falls into the same category as die(), warning(), and
error(). It is a way to consistently format (and with a better
design to line-wrap, than its older brethren) messages.
We do not have "die_if(condition, format, ...)", but if there were
such a thing, that would be a good analogy to advice_if_enabled().
And a short-hand of die_if() would not make die() any unnecessary.
prev parent reply other threads:[~2022-01-31 17:46 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-01-28 9:33 BUG: Various "advice.*" config doesn't work Ævar Arnfjörð Bjarmason
2022-01-31 16:16 ` Taylor Blau
2022-01-31 17:28 ` Junio C Hamano
2022-01-31 17:34 ` Taylor Blau
2022-01-31 17:46 ` Junio C Hamano [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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=xmqqv8xziyrr.fsf@gitster.g \
--to=gitster@pobox.com \
--cc=avarab@gmail.com \
--cc=git@vger.kernel.org \
--cc=jonathantanmy@google.com \
--cc=me@ttaylorr.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.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.