Re: [PATCH] Add gitattributes file making whitespace checking pickier

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



bdowning@xxxxxxxxx (Brian Downing) writes:

> On Sun, Feb 10, 2008 at 02:52:50AM -0800, Junio C Hamano wrote:
>>  - It is Ok to indent with all spaces the Python and Elisp
>>    sources in the contrib/ area.
>
> Should contrib simply be exempt from all rules?  Certainly with my
> contribution to contrib (contrib/stats/packinfo.pl) I made no effort to
> conform to the Git style because I thought contribs were auxiliary to
> Git.  (It contains indention with all spaces, which is my personal
> default style.)

You are quoting an older draft.  The rules applied to 'master'
is actually a bit more lenient:

 - Unless otherwise specified, indent with SP that could be
   replaced with HT are not "bad".  But SP before HT in the
   indent is "bad", and trailing whitespaces are "bad".

 - For C source files, initial indent by SP that can be replaced
   with HT is also "bad".

 - Test scripts in t/ and test vectors in its subdirectories can
   contain anything, so we make it unrestricted for now.

So your particular "indent without HT" is generally accepted,
and considered a violation only in C sources.

I see what you mean by "excempt from all rules" and it is
certainly a valid approach, but I at the same time think minimal
whitespace policy should be there, and flagging trailing spaces
and SP before HT is a good idea.
-
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux