The case against "eol = clean"
Marius Kruger
amanic at gmail.com
Mon Mar 30 06:34:20 BST 2009
2009/3/28 Ian Clatworthy <ian.clatworthy at internode.on.net>:
> Wondering out loud, maybe a separate "whitespace" filter is
> the better place for this? That filter could do stuff like:
>
> * warn about mixed line endings being detected
> * warn about trailing whitespace on end of lines
> * warn about a missing newline at end of file
> * strip trailing whitespace at end of lines
> * replace tabs with spaces or vice versa
> * etc.
>
> Imagine something like ...
>
> [name *]
> whitespace = warn-mixed-newlines,trim-trailing-whitespace,expand-tabs
fwiw, I intended to implement the above (except the line-endings and
expand-tabs, but that can be added)
with the bzr-text-checker plugin (https://launchpad.net/bzr-text-checker).
I'm busy changing over to a rules-based config and I'm thinking of the
following ATM (suggestions welcome):
[name *.py, *.java, NEWS, README]
trailing_whitespace=fail
leading_tabs=warn
newline_at_eof=warn
long_line_length=80
long_lines=ask
btw. are we going to have location based rules like locations.conf?
because I'd like everything in /stuph/projects/bzr/bzr.repo to have
long_line_length=79
and everywhere else long_line_length=80
--
<| regards
U| Marius
More information about the bazaar
mailing list