在执行 git add . 命令后,出现如下错误
warning: LF will be replaced by CRLF in android/app/build.gradle.
The file will have its original line endings in your working directory
原因是 windows 中的换行符为 CRLF,而在 linux 下的换行符为 LF,存在符号转义问题。
解决办法
git config --global core.autocrlf false