Chinaunix首页 | 论坛 | 博客
  • 博客访问: 1859014
  • 博文数量: 211
  • 博客积分: 464
  • 博客等级: 下士
  • 技术积分: 3794
  • 用 户 组: 普通用户
  • 注册时间: 2011-01-24 18:25
个人简介

阿弥陀佛

文章分类

全部博文(211)

文章存档

2020年(2)

2019年(3)

2018年(5)

2017年(6)

2016年(10)

2015年(9)

2014年(73)

2013年(90)

2012年(13)

分类: 服务器与存储

2014-01-15 14:20:50

# Add the remote, call it "upstream":
git remote add upstream
# Fetch all the branches of that remote into remote-tracking branches,
# such as upstream/master:
git fetch upstream
# Make sure that you're on your master branch:
git checkout master
# Rewrite your master branch so that any commits of yours that
# aren't already in upstream/master are replayed on top of that
# other branch:
#此时本地的master已经更新
git rebase upstream/master
#将本地的master同步到服务器端的master
git push -f origin master

git add * 向服务器端要更新的内容添加当前所有文件。
git commit -m "push all" 告诉服务器要提交哪些修改,更新所带的信息为push all。
git pull  将数据从远端数据拿过来
git push -u origin master 实现更新到远端。

在本地创建一个分支
git add -all
git commit -m '修改的信息"
git branch branch1
git push origin branch1 这样将branch1同步到github上的相应分支上去。

阅读(2728) | 评论(0) | 转发(0) |
1

上一篇:keepalive的作用

下一篇:程序优化方法

给主人留下些什么吧!~~