I still have XP on my laptop and have installed Git so that I can do some work on it. When I clone a repository from my server (which is linux) it automatically adds carriage returns onto each line. So now Git thinks that every file has been modified when, in fact, they haven't.
I've tried adding the following lines to my .gitconfig file to no avail
[core]
autocrlf = true
or
[core]
autocrlf = input
I have also tried running
git config core.autocrlf <value>
within the repository in question, and then reset hard to head. This also didn't seem to work. Any help would be appreciated.
text eol=crlf Git will always convert line endings to CRLF on checkout. You should use this for files that must keep CRLF endings, even on OSX or Linux. text eol=lf Git will always convert line endings to LF on checkout. You should use this for files that must keep LF endings, even on Windows.
autocrlf is set to false on a fresh install of Git, meaning Git won't perform any line ending normalization. Instead, Git will defer to the core. eol setting to decide what line endings should be used; core. eol defaults to native , which means it depends on the OS you're using.
it really doesn't matter, each cloned copy of a repo is the same as any other (assuming there were no new commits between clone operations).
Why not "autocrlf = false?".
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With