首页 > 其他 > 详细

Git使用帮助

时间:2015-11-27 19:52:54      阅读:309      评论:0      收藏:0      [点我收藏+]

1. 本地创建新项目

git init
git add .
git commit -m "First commit"

2. 本地代码同步Push到远程仓库

git remote add origin "https://github.com/zwffff/ag.git"
git push -u origin master

3. push到远程仓库,出现“failed to push some refs to git"错误

git pull --rebase origin master

4. git pull --rebase origin master,出现“Cannot pull with rebase: You have unstaged changes."错误

git stash
git pull --rebase origin master

 5. 创建.gitignore忽略文件

touch .gitignore

 

Git使用帮助

原文:http://www.cnblogs.com/zwffff/p/4928135.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!