Line Endings
-
Using GitExtension (http://code.google.com/p/gitextensions/) and having trouble with pfSense line endings.
With core.autocrlf set to true it wants to change LF to CRLF
With core.autocrlf set to input it wants to change CRLF to LF
With core.autocrlf set to false it wants to change CRLF to LFI was of the understanding that true was the desired setting for cross platform and was to commit with Unix-style line endings (LF).
What should the line endings setting be for working with pfSense?
Thanks
Line Endings Settings and Commit Warnings:
Checkout Windows-style, commit Unix-style line endings ("core.autocrlf" is set to "true")
warning: LF will be replaced by CRLF in etc/inc/upgrade_config.inc.
The file will have its original line endings in your working directory.Checkout as-is, commit Unix-style line endings ("core.autocrlf" is set to "input")
warning: CRLF will be replaced by LF in conf.default/config.xml.
The file will have its original line endings in your working directory.Checkout as-is, commit as-is ("core.autocrlf" is set to "false")
warning: CRLF will be replaced by LF in conf.default/config.xml.
The file will have its original line endings in your working directory. -
Leave it on auto.
The line endings git puts on your machine are whatever your OS wants.
The line endings git will commit on the other hand, are always going to be LF only.
We have a .gitattributes file that also tells the git client how they should be handled directly so in most cases you shouldn't have to touch the settings, just leave it on auto.
-
Okay.ย So just ignore the warning when doing a commit that LF is going to be replaced with CRLF?
warning: LF will be replaced by CRLF in etc/inc/upgrade_config.inc.
The file will have its original line endings in your working directory. -
Yep, that's normal.