Thread (19 messages) flat view 19 messages, 3 authors, 2016-06-15

Re: [PATCH] init-db: Store current value of autocrlf

From: Dmitry Potapov <hidden>
Date: 2016-06-15 22:44:25

On Sun, Mar 23, 2008 at 10:34:13AM +0100, Steffen Prohaska wrote:
Storing the current value of autocrlf to preserve it for this repository
even if the global setup changes is a good idea.  Changing autocrlf
later is tricky because the work tree's line endings depend on the
settings during checkout.  Therefore, it makes sense to preserve the
value of autocrlf that exists during the first checkout.  In this
regards autocrlf is different from, for example, author, because author
can be easily changed later without requiring any conversion of existing
files in the work tree.

This commit modifies the initialization of a new repository to store the
current value of autocrlf.
NAK

While I agree that preserving autocrlf may be a good idea, I don't like
that the idea of making an exception for autocrlf and treating the global
settings for it differently than for other variables -- as something that
should be copied on init. We have templates for that, so autocrlf should
be placed into templates/config and then it will be automatically copied
when a new repository is created. I have tested that now, and it works.


Dmitry
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help