[RFC] Fix leading and trailing spaces.

Ondřej Bílka neleai at seznam.cz
Mon Jul 8 14:41:17 CEST 2013


I am writing tool to help with various style issues. This will
simplify code review as these issues will be solved automatically.

As prerequisite I need to have to start with consistent codebase.
It is possible to fix only files that are touched by commit but this can
introduce unrelated changes which is distraction to review.

As first step I need to know what is policy of leading/trailing spaces.

Are leading ws all spaces or tabs followed by less than 8 spaces?
Are there some form-feeds and are they useful?

I have for second choice patch ready on

Which was generated by

Now I can also check typos in comments and warn about missing

What else do you want to check/add warning... ?
I now can do warning as git hook. I would welcome adding an mercurial
hook support.

Please use flags to ignore whitespaces like

hg annotate -w
git blame -w
patch -l
git apply --ignore-space

More information about the gmp-devel mailing list