From: Junio C Hamano <gitster@pobox.com>
To: "Wesley J. Landaker" <wjl@icecavern.net>
Cc: git@vger.kernel.org
Subject: Re: [PATCH] Documentation: indent-with-non-tab uses tabwidth setting, not just 8
Date: Sun, 16 Sep 2012 23:03:29 -0700 [thread overview]
Message-ID: <7v8vc9w5hq.fsf@alter.siamese.dyndns.org> (raw)
In-Reply-To: <7v392hxm94.fsf@alter.siamese.dyndns.org> (Junio C. Hamano's message of "Sun, 16 Sep 2012 22:16:07 -0700")
Junio C Hamano <gitster@pobox.com> writes:
>> @@ -559,8 +559,8 @@ core.whitespace::
>> * `space-before-tab` treats a space character that appears immediately
>> before a tab character in the initial indent part of the line as an
>> error (enabled by default).
>> -* `indent-with-non-tab` treats a line that is indented with 8 or more
>> - space characters as an error (not enabled by default).
>> +* `indent-with-non-tab` treats a line that is indented with `tabwidth` space
>> + characters or more as an error (not enabled by default).
>
> I would rather see this part left untouched.
>
> Your new text will force people who are not interested in using
> non-standard tab width to read through the bulletted list, only to
> find "The default tab width is 8". I think that is a regression in
> the documentation for more common readers.
>
> When somebody wants to use `indent-with-non-tab` and gets offended
> by the seemingly hardcoded "8" in the description, the reader has
> incentive to find out if there is a way to change that 8, and will
> find `tabwidth=<n>` in the same bulletted list described, with the
> effect it has on both `indent-with-non-tab` and `tab-in-indent`.
>
> I think that should be sufficient for people who do use non-standard
> tab width using tabwidth=<n>.
An alternative would be to lose the "8" (or `tabwidth`) from that
description. I've always thought that the description of `tabwidth`
is clear enough that "8" in the patch is not a hardcoded non-overridable
value but is merely a default, but after reading that section a few
more times, I no longer think that is the case.
I originally wrote "8 or more space" but that wasn't because I
thought it was important to stress "8 is the default", but because I
didn't think of a better way to say what I wanted to say, which was
"if you are filling the indentation with spaces when you could have
just typed a tab with a few spaces, this error triggers", in other
words "use of this is to encourage indenting with tabs".
next prev parent reply other threads:[~2012-09-17 6:03 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-09-16 17:12 [PATCH] Documentation: indent-with-non-tab uses tabwidth setting, not just 8 Wesley J. Landaker
2012-09-17 5:16 ` Junio C Hamano
2012-09-17 5:41 ` Wesley J. Landaker
2012-09-17 6:03 ` Junio C Hamano [this message]
2012-09-17 14:20 ` Wesley J. Landaker
2012-09-17 14:22 ` [PATCH] Documentation: indent-with-non-tab uses "equivalent tabs" not 8 Wesley J. Landaker
2012-09-17 17:23 ` Junio C Hamano
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=7v8vc9w5hq.fsf@alter.siamese.dyndns.org \
--to=gitster@pobox.com \
--cc=git@vger.kernel.org \
--cc=wjl@icecavern.net \
/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 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 NNTP newsgroup(s).