From: Peter S. <pe...@st...> - 2010-12-07 20:52:13
|
Pete Batard wrote: > Just tested grep, more (less), vim, and a few other command line tools > in cygwin and MinGW, and at least for the versions I have, they are CRLF > aware. Very nice. > They will produce LF'd output however, so if we were to use grep to > create a source, we'd get CRLF -> LF conversion that we might not want. Actually, if autocrlf=true is being used and git considers the file text, then that is fine. It will be converted back to all LF before writing to the repo. But safecrlf=true would abort the commit, because the file would be recreated with all CRLF (different from current file) on next checkout. safecrlf=true ensures that nothing will be "corrupted." > So the question is whether we consider that the possibility of > people using text tools that can't handle CRLF properly in > cygwin/MinGW outweighs the ability to move files around between > environments. No. This is something that every person using git has to consider themselves (how they should set core.autocrlf) and nothing that we do in our repo forces any user in any direction. > I'll leave you guys decide on what you think should take precedence. I am still happy to hear about any problems that anyone encounters with my suggested solution, but the more ways that I describe how it works, the more confident I get that it is the right thing to do. //Peter |