[issue2704] files don't update to new line ending format when eol extension enabled/disabled

Paul K bugs at mercurial.selenic.com
Tue Mar 15 20:59:51 UTC 2011


New submission from Paul K <bobpaul+hgbts at gmail.com>:

related to Issue2287, msg13120

Observed Behavior
If the eol extension is enabled or disabled, 'hg up' does not show any files
need to be updated. 

Expected Behavior
If the working directory differs from how the eol extension expects the
working directory to look, files differ and should be updated. That is:
native - lf; repo - crlf -- if eol is disabled and working directory is
native, files should update to repo format. If eol is enabled and working
directory is repo format, files should update to native.

Work around
After enabling or disabling the eol extension, check out rev1, then checkout
the rev you wish to work on. This should show the maximum possible number of
changes and update all of the files. Alternately, delete all tracked files
and 'hg up -C' to restore them.

Rationale:
1. I like to work in unix line endings. A braindead tool that's required in
the project and cannot be altered requires files use Windows line endings. I
rarely need to use the tool, so having the repo in Windows line endings is
generally sufficient. When I do run the tool, I disable the eol extension
and (would like to) update such that I now have Windows line endings on all
my files. After using the tool, I (would like to) re-enable the extension
and once again have native line endings.

2. eol is an extension. Simply having .hgeol in the working directory is not
sufficient to ensure all users are using the extension, just that they'll
share a configuration once they do enable it. A user joins, does some work,
and complains about the eol format. We direct him to enable the eol
extension. Now his working directory is no longer consistent, with some
files as native line endings and some as the repo format.

----------
messages: 15672
nosy: bobpaul
priority: wish
status: unread
title: files don't update to new line ending format when eol extension enabled/disabled
topic: eol

____________________________________________________
Mercurial issue tracker <bugs at mercurial.selenic.com>
<http://mercurial.selenic.com/bts/issue2704>
____________________________________________________


More information about the Mercurial-devel mailing list