zoukankan      html  css  js  c++  java
  • git创建和删除远程分支

    问题描述:

              使用git创建和删除远程分支

    问题解决:

                 (1)git创建本地分支

    git chuangjain

    注:   

            如上所示,使用命令 git branch -a 查看所有分支情况,以及当前分支

             使用命令git branch temporary 创建分支temporary

             使用命令 git checkout temporary 切换到temporary分支

         (2)git创建远程分支

    gittemporary

    注:

             如上所示,在本地分支 temporary中创建文件 并commit之后,创建远程分支 git   push  origin  temporary:temporary

          其中origin是远程仓库,第一个temporary是本地分支,第二个temporary是远程新建的分支(github中为例子)

    fenzhi

    注:

           如上图所示  temporary是刚才创建的远程分支

        (3)删除远程分支

               1)使用命令 git  push origin --delete 远程分支名   

    git delete

    注:

          使用命令  git    push   origin --delete hello (hello为远程分支名称)

    shanzhi

    注:

             github中删除远程分支hello之后效果图

           2)使用命令  git   push origin  :temporary

    shantemp

    注:

            使用命令  git   push origin  :远程分支名

    shan tempe

    注:

              删除远程分支之后的效果图

  • 相关阅读:
    POJ
    Parallel Computing–Cannon算法 (MPI 实现)
    POJ
    POJ 2240
    IOS
    iOS
    js遍历map匹配数据和js遍历数组匹配map数据
    vue v-on:click传递动态参数
    vue 权限控制按钮3种样式、内容、以及跳转事件
    vue v-show与v-for同时配合v-bind使用并在href中传递多个参数的使用方法
  • 原文地址:https://www.cnblogs.com/luosongchao/p/3408363.html
Copyright © 2011-2022 走看看