Alternatives to EOL extension
Ernie Rael
err at raelity.com
Thu Jan 15 16:13:09 UTC 2015
On 1/15/2015 6:54 AM, Carsten Fuchs wrote:
> Hi all,
>
> many thanks for everyone's answers!
>
> Thinking more about it, if I understand you all right, the proper
> alternative to the EOL extension is to, for example, write a custom
> script that checks our source code, e.g. for proper EOL style,
> trailing whitespace, character encoding, and so on, and then for us
> (the crucial step!) to treat this source code "check" script very much
> like the source code "build" script. That is, like we'd not commit any
> changes that don't built, we'd not commit changes for which the
> "check" script fails.
So you can see why the relatively new eol extension (replacing the old
win32text extension) is provided. Seems more reliable than most ad hoc
solutions. I don't recall seeing mention in this thread, but the repo
server can be configured with a hook to forbid incorrect line endings
from being committed (I've never done this, so can't say much about how).
>
> Would you say that this understanding is principally correct
> (especially wrt. Mercurial best practices / its "last resort" EOL
> extension)?
>
> Best regards,
> Carsten
> _______________________________________________
> Mercurial mailing list
> Mercurial at selenic.com
> http://selenic.com/mailman/listinfo/mercurial
More information about the Mercurial
mailing list