码迷,mamicode.com
首页 > 其他好文 > 详细

git遇到的问题

时间:2020-02-24 12:48:48      阅读:92      评论:0      收藏:0      [点我收藏+]

标签:内容   upd   replace   windows   details   directory   help   hat   its   

warning: LF will be replaced by CRLF in about/index.html.
The file will have its original line endings in your working directory

原因是存在符号转义问题;windows的换行符为CRLF,Linux下的为LF。执行:

 git config --global core.autocrlf false 

hint: Updates were rejected because the remote contains work that you do
hint: not have locally. This is usually caused by another repository pushing
hint: to the same ref. You may want to first integrate the remote changes
hint: (e.g., ‘git pull ...‘) before pushing again.
hint: See the ‘Note about fast-forwards‘ in ‘git push --help‘ for details.

勾选了 Initialize this repository with a README这项,导致远程仓库不为空,解决办法,先将远程仓库的内容合并到本地,然后再上传即可,命令如下:

 git pull --rebase origin master

git push -u origin master 

 

git遇到的问题

标签:内容   upd   replace   windows   details   directory   help   hat   its   

原文地址:https://www.cnblogs.com/chenguifeng/p/12356205.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!