1. add a new branch

cd workspace
git branch user1/newbranch1
git checkout user1/newbranch1

or

git checkout -b user2/newbranch2

2. when user1/newbranch1 development finished, merge it into master branch.

git checkout master
git merge user1/newbranch1

delete branch user1/newbranch1

git branch -d user1/newbranch1

Git Note - Branch的更多相关文章

  1. Git Your branch is ahead of 'origin/master' by X commits解决方法

    (1)方法1:git fetch origin (2)方法2(代码还需要):git push origin (3)方法3 (代码不需要):git reset --hard origin/$branch ...

  2. Git Note

    Git 参考 http://chengshiwen.com/article/head-first-git/ 文件状态 Git目录: (git directory),亦即Git仓库,一般对应项目根目录下 ...

  3. git: Your branch and 'origin/master' have diverged

    git: Your branch and 'origin/master' have diverged - how to throw away local commits? - Stack Overfl ...

  4. Git master branch has no upstream branch的解决

    Git master branch has no upstream branch的解决 在push代码时,出现“git master branch has no upstream branch”问题的 ...

  5. git branch & git remote branch

    git branch & git remote branch $ git branch -h usage: git branch [<options>] [-r | -a] [-- ...

  6. git branch(git 的branch 使用方法)

    查看分支:         $ git branch    该命令会类出当先项目中的所有分支信息,其中以*开头的表示当前所在的分支.参数-r列出远程仓库中的分支,而-a则远程与本地仓库的全部分支. 创 ...

  7. git 创建branch分支

    开发者user1 负责用getopt 进行命令解析的功能,因为这个功能用到getopt 函数,于是将这个分支命名为user1/getopt.(1)确保是在开发者user1的工作区中cd /home/j ...

  8. git 创建branch分支【转】

    转自:http://www.cnblogs.com/jackluo/p/3499731.html 开发者user1 负责用getopt 进行命令解析的功能,因为这个功能用到getopt 函数,于是将这 ...

  9. Git CMD - branch: List, create, or delete branches

    命令格式 git branch [--color[=<when>] | --no-color] [-r | -a] [--list] [-v [--abbrev=<length> ...

随机推荐

  1. Java缓存相关memcached、redis、guava、Spring Cache的使用

    随笔分类 - Java缓存相关 主要记录memcached.redis.guava.Spring Cache的使用 第十二章 redis-cluster搭建(redis-3.2.5) 摘要: redi ...

  2. PHP扩展类ZipArchive实现压缩解压Zip文件和文件打包下载 && Linux下的ZipArchive配置开启压缩 &&搞个鸡巴毛,写少了个‘/’号,浪费了一天

    PHP ZipArchive 是PHP自带的扩展类,可以轻松实现ZIP文件的压缩和解压,使用前首先要确保PHP ZIP 扩展已经开启,具体开启方法就不说了,不同的平台开启PHP扩增的方法网上都有,如有 ...

  3. Hive-表连接

    Hive只支持等值连接,即ON子句中使用等号连接,不支持非等值连接. Hive内置的数据存储类型,TextFile, SequenceFile, ORC(列式存储) 如果连接语句中有WHERE子句,会 ...

  4. HttpContext.Current并非无处不在

    阅读目录 开始 无处不在的HttpContext HttpContext.Current到底保存在哪里? HttpContext并非无处不在! 如何获取文件绝对路径? 异步调用中如何访问HttpCon ...

  5. 超文本传输协议http详解

    HTTP是一个属于应用层的面向对象的协议,由于其简捷.快速的方式,适用于分布式超媒体信息系统.它于1990年提出,经过几年的使用与发展,得到不断地完善和扩展.目前在WWW中使用的是HTTP/1.0的第 ...

  6. java.util.ConcurrentModificationException异常分析

    Java在操作ArrayList.HashMap.TreeMap等容器类时,遇到了java.util.ConcurrentModificationException异常.以ArrayList为例,如下 ...

  7. Node.js究竟是什么?

    来源:https://www.ibm.com/developerworks/cn/opensource/os-nodejs/index.html?ca=drs#ibm-pcon   Node 旨在解决 ...

  8. fabric本地一键部署LAMP

    一.添加普通用户jeff执行sudo时无需输入密码 $ sudo vim /etc/sudoers ---------------------------------------> ## All ...

  9. Redis 与 Lua Script

    [Redis Script] 1.EVAL script numkeys key [key ...] arg [arg ...] 从 Redis 2.6.0 版本开始,通过内置的 Lua 解释器,可以 ...

  10. ArcGIS GP服务的发布及调用

    参考https://www.jianshu.com/p/5331fa708fe5