git上传 warning 、上传fail 解决办法

1、Git上传warning:

git上传 warning 、上传fail 解决办法_第1张图片

警告信息:warning: LF will be replaced by CRLF in mingw64/lib/tcl8.6/tzdata/Pacific/Rarotonga.
The file will have its original line endings in your working directory

解决办法:git config core.autocrlf false  执行完此命令,重新执行 git add .  最后的 小点儿不要忘记哦

2、Git上传错误:

git上传 warning 、上传fail 解决办法_第2张图片

错误信息:To https://github.com/..........git
 ! [rejected]        master -> master (fetch first)
error: failed to push some refs to 'https://github.com/......git'

解决办法:$ git pull --rebase origin master

执行完之后重新执行:$ git push origin master

完美解决!

你可能感兴趣的:(git)