[Lemon-devel] TABs vs. SPACEs

Balazs Dezso deba at inf.elte.hu
Sun Jul 6 16:25:40 CEST 2008


Hi, 

I support this idea, but I would like to recommend a few more, the trailing 
spaces should be removed from each line (maybe if the line contains not 
whitespace characters), and the long lines (excluded some special cases) 
should be wrapped.

I also would like to recommend some automatic checking, which coule be done 
with the usage of hg commit hooks. A checker script could be included into the 
repo, which could check the changeset before each local commit.

Best, Balazs

On Sunday 06 July 2008 10:59:26 Alpár Jüttner wrote:
> Hi,
>
> Currently we uses two spaces for indentation. We follow this very
> consistently throughout the repository. However it is not clear how to
> use TABs. By default, Emacs (which is the default editor of most of us)
> automatically replaces each 8 spaces with a tab. This is nice but may
> cause problems for people for using some less advanced editor and often
> leads accidental whitespace changes in the changesets.
>
> The first question is: should we get rid of tabs?
>
> If yes, the second one is: how?
>
> It is possible to configure Emacs not to use tabs. In fact there are too
> options.
>       * This option can be set globally in Emacs. Then everybody must
>         configure his/her Emacs in this way and use it for all projects
>         and all files. Not very appealing.
>       * It can be set as a file local variable. To to it automatically,
>         the fist line of the each file in the repo should me modified.
>         This is nice, but some extra care should be taken when a new
>         file in created of ported from svn.
>
> If we decide to change,
>       * All source files should be untabified and the headers should be
>         modified. I can do it quite easily, but is must be done at a
>         point when there are no patches waiting for review.
>       * Later, the same must be done with all new ports. (Unless we also
>         untabify the svn repo.)
>               * Probably, the scripts/update-copyright-header.sh should
>                 also be modify to also untabify the source files.
>
> I would like to hear your opinion.
>
> Best regards,
> Alpar
>
>
>
> _______________________________________________
> Lemon-devel mailing list
> Lemon-devel at lemon.cs.elte.hu
> http://lemon.cs.elte.hu/mailman/listinfo/lemon-devel




More information about the Lemon-devel mailing list