git create remote branch (五)
admin@PC-panzidong MINGW64 ~/WebstormProjects/backEndServer (master)
查看本地分支信息
$ git branch
* master
admin@PC-panzidong MINGW64 ~/WebstormProjects/backEndServer (master)
查看分支最后一次提交信息
$ git branch -v
* master 1c4ed79 #AHB-20 add get device subdevice list
admin@PC-panzidong MINGW64 ~/WebstormProjects/backEndServer (master)
创建本地分支
$ git branch test-protocol
admin@PC-panzidong MINGW64 ~/WebstormProjects/backEndServer (master)
查看本地分支信息
$ git branch
* master
test-protocol
admin@PC-panzidong MINGW64 ~/WebstormProjects/backEndServer (master)
查看远程分支信息
$ git branch -r
origin/HEAD -> origin/master
origin/master
admin@PC-panzidong MINGW64 ~/WebstormProjects/backEndServer (master)
#查看所有的分支信息
$ git branch -a
* master
test-protocol
remotes/origin/HEAD -> origin/master
remotes/origin/master
admin@PC-panzidong MINGW64 ~/WebstormProjects/backEndServer (master)
#切换到本地test-protocol分支
$ git checkout -b test-protocal
Switched to a new branch 'test-protocal'
admin@PC-panzidong MINGW64 ~/WebstormProjects/backEndServer (test-protocal)
# 查看分支信息
$ git branch -a
master
* test-protocal
test-protocol
remotes/origin/HEAD -> origin/master
remotes/origin/master
admin@PC-panzidong MINGW64 ~/WebstormProjects/backEndServer (test-protocal)
# 将本地test-protocol分支推送至远端
$ git push origin test-protocal:test-protocal
Total 0 (delta 0), reused 0 (delta 0)
remote:
remote: Create a pull request for 'test-protocal' on GitHub by visiting:
remote: https://github.com/13701761349/backEndServer/pull/new/test-protoca
remote:
To https://github.com/13701761349/backEndServer.git
* [new branch] test-protocal -> test-protocal
admin@PC-panzidong MINGW64 ~/WebstormProjects/backEndServer (test-protocal)
$ git branch -a
master
* test-protocal
test-protocol
remotes/origin/HEAD -> origin/master
remotes/origin/master
remotes/origin/test-protocal
admin@PC-panzidong MINGW64 ~/WebstormProjects/backEndServer (test-protocal)
$
admin@PC-panzidong MINGW64 ~/WebstormProjects/backEndServer (master)
$ git branch -r
origin/HEAD -> origin/master
origin/master
origin/test-protocal
admin@PC-panzidong MINGW64 ~/WebstormProjects/backEndServer (master)
#拉取远程分支版本
#git checkout -b 本地分支名 origin/远程分支名
$ git checkout -b test-protocal origin/test-protocal
Switched to a new branch 'test-protocal'
Branch 'test-protocal' set up to track remote branch 'test-protocal' from 'origin'.
git create remote branch (五)的更多相关文章
- git pull的时候提示git pull <remote> <branch>
yuanqiao@yuanqiao-PC MINGW64 /h/WorkSpace/git/dadeTest (dev)$ git pullremote: Enumerating objects: 7 ...
- git之remote branch controller(远程分支控制)
1.创建本地分支 git branch //查看远程分支 git checkout -b branch_name //创建远程分支 在查看分支git branch 2.将分支提交到远程仓库 此时远程 ...
- git branch & git remote branch
git branch & git remote branch $ git branch -h usage: git branch [<options>] [-r | -a] [-- ...
- 【IDEA】 Can't Update No tracked branch configured for branch master or the branch doesn't exist. To make your branch track a remote branch call, for example, git branch --set-upstream-to origin/master
IDEA点击GIT更新按钮时,报错如下: Can't UpdateNo tracked branch configured for branch master or the branch doesn' ...
- Rename a local and remote branch in git
If you have named a branch incorrectly AND pushed this to the remote repository follow these steps b ...
- git clone all branch and create a empty branch
/******************************************************************** * git clone all branch and cre ...
- Git checkout on a remote branch does not work
I believe this occurs when you are trying to checkout a remote branch that your local git repo is no ...
- [Git] How to rename your remote branch
Rename your local foo branch with bar: git branch -m foo bar Remember this will add the new branch w ...
- 使用VSTS的Git进行版本控制(五)——从Team Services Portal管理分支
使用VSTS的Git进行版本控制(五)--从Team Services Portal管理分支 任务1:创建新分支 1.登录Visual Studio Team Services账号 2.打开Code ...
随机推荐
- 深度学习-强化学习(RL)概述笔记
强化学习(Reinforcement Learning)简介 强化学习是机器学习中的一个领域,强调如何基于环境而行动,以取得最大化的预期利益.其灵感来源于心理学中的行为主义理论,即有机体如何在环境给予 ...
- t100 常用公用變數
g_enterprise 目前的企業代碼,將限制使用者所能閱讀的資料內容g_prog 目前執行的作業編號,用於變換畫面顯示資料與產生系統資訊,不可變更g_code 目前執行的程式代碼(4gl)名稱,不 ...
- 【解决方案】文件上具有 Web 标记,请删除 Web 标记
错误: 无法处理文件 Form1.resx,因为它位于 Internet 或受限区域中,或者文件上具有 Web 标记.要想处理这些文件,请删除 Web 标记. 解决方法: 文件-右键-属性 点击”解 ...
- Visual Studio 2019 XAML Hot Reload功能介绍
Visual Studio 2019提供了XAML Hot Reload功能,这个功能可以让WPF程序运行以后仍然可以修改XAML代码,并实时显示. XAML Hot Reload功能在Blend F ...
- 一个非常有趣的爬虫小练习带ocr识别的
有个小的想法,想找一找 形近字 .百度一搜索,百度文库有一个,收费4元.而且我觉得字数不是太多.想自己弄一个,于是找到了 这个网站 http://www.fantiz5.com/xingjinzi/ ...
- 【开发工具】- myeclipse安装主题
你想用IDEA那样炫酷的符合90后气质的主题吗?废话不多说,按照下边步骤就可以安装像IDEA一样超级炫酷的主题. 下载主题 1.进入插件官网(http://eclipsecolorthemes.org ...
- Synchronized可重入锁分析
可重入锁又称递归锁,是指在同一个线程在外层方法获取锁的时候,再进入该线程的内层方法会自动获取锁(前提是锁对象必须是同一对象或者class), 不会因为之前已经获取过还没实方而发生阻塞.即同一线程可执行 ...
- WPF应用打包流程
1,安装工程模板插件Microsoft Visual Studio Installer Projects https://marketplace.visualstudio.com/items?item ...
- Gitlab配置webhooks实现自动化部署
Gitlab 自动化部署 原理介绍 配置gitlab当push动作的时候,访问服务器上的一个链接比如www.shenke.group/hook.php hook.php里面写着一行代码,会让服务器gi ...
- win10 提示该文件没有与之关联的应用来执行该操作
将下面代码复制进一个文本文档,然后将文本文档的txt后缀改成bat.双击运行,可以解决问题. 问题发生原因是之前通过注册表去除了桌面图标的快捷方式的小标志. /-------------------- ...