git关掉“LF将被CRLF取代”警告
我明白警告是什么,如何closuresfunction,但我需要的是closures警告本身。 请帮助?
您可以使用closures警告
git config --global core.safecrlf false (这只会closures警告,而不是function本身。)
 你应该使用core.autocrlf input和core.eol input 。 或者只是不要让git用autocrlf false改变行结尾,并用core.whitespace cr-at-eol来消除比较中crlfs的突出显示。 
希望这可以帮助
我用这种方式:
把你当前的文件保存在Git中,这样你的工作都不会丢失。
git add . -u git commit -m "Saving files before refreshing line endings"从Git的索引中删除每个文件。
git rm --cached -r .重写Git索引来获取所有新的结尾。
git reset --hard将所有更改的文件添加回来,并准备提交。 这是你的机会,检查哪些文件,如果有的话,没有改变。
git add . # It is perfectly safe to see a lot of messages here that read # "warning: CRLF will be replaced by LF in file."将更改提交到您的存储库。
git commit -m "Normalize all the line endings"
 您正在寻找core.whitespace选项(请参阅git config --help获取详细信息)。 
你可以像这样设置这个选项:
 $ git config core.whitespace cr-at-eol