1

Though I executed LF will be replaced by CRLF in git - What is that and is it important?

git config core.autocrlf true

I still get

warning: LF will be replaced by CRLF in .../.vscode/taskmarks.json

How to really fix this ?

user310291
  • 33,174
  • 71
  • 241
  • 439

1 Answers1

1

See "git replacing LF with CRLF":

The warning "LF will be replaced by CRLF" says that you (having autocrlf=true) will lose your unix-style LF after commit-checkout cycle (it will be replaced by windows-style CRLF).
Git doesn't expect you to use unix-style LF under windows.

(Hence the warning)

Make sure you don't have a .gitattributes directive like * text=auto.
You can set core.safecrlf to false, but not with Git 2.17/2.18: see "Trying to commit Git files but getting: fatal: LF would be replaced by CRLF in <some file in repo>": you would need Git 2.19 for that.

VonC
  • 1,042,979
  • 435
  • 3,649
  • 4,283