as indicated in another answer,
git config --global core.autocrlf false
If you have files that correctly save line endings as crlf, you should also suppress the "cr" selection. Git diff and other patch outputs will highlight potentially problematic spaces. You can suppress this with:
git config --global core.whitespace cr-at-eol
Remember that --global
will make this effective for all your repositories when you log in as the same user on the machine. To apply the setting to any user, use --system
. Conversely, you can only apply the setting to the current repo with --local
. --local
implied if the region parameter is not set.
source share