What Does Value of core.autocrlf Git Setting Mean?

I have been confused about the core.autocrlf setting in the past and I found out pretty clear explanation on Git for windows installer so I thought I’d share it here so others can benefit from it.

core.autocrlf=true

On checkout, git will convert line endings to window style i.e. CRLF and on commit, it will convert to unix line endings i.e. LF

core.autocrlf=input

On checkout, git will not do any conversion and preserve line ending but on commit, it will convert to unix line ending i.e. LF

core.autocrlf=false

On checkout, git will not do any conversion and preserve line ending also
on commit, it will not do any conversion and preserve line endings.

Leave a Reply

Your email address will not be published. Required fields are marked *