人工改 在vscode中,可以修改状态栏右下角的CRLF,改为LF。 但一般项目的文件很多,一个个改太费劲了,请看下面的方法。 配置改 使用editorconfig,在项目根目录下新建.editorconfig文件,内容如下: # top-most EditorConfig file root = true # Unix-style newlines with a newline ending every file [*] # lf, ...