美文网首页
See the 'Note about fast-forward

See the 'Note about fast-forward

作者: 纳兰怮翌 | 来源:发表于2020-07-22 11:53 被阅读0次

记录一下终端提交代码的几行命令,不知道是不是由于老了,始终记不住了
1、git init
2、git add .
3、git commit -m "添加你的注释,一般是一些更改信息"
4、git remote add origin HTTPS链接
5、git pull origin master
6、git push origin master
其中第六步可能出现的错误


D1315969-20E4-4A1F-9156-E87475C5A6C7.png

执行

没有设置默认分支
git pull origin master --allow-unrelated-histories

或者

设置了默认分支
git pull --allow-unrelated-histories

相关文章

网友评论

      本文标题:See the 'Note about fast-forward

      本文链接:https://www.haomeiwen.com/subject/szezkktx.html