Visual Studio 2013 - Git - 获取远程分支 [英] Visual Studio 2013 - Git - Fetch remote branches

查看:2075
本文介绍了Visual Studio 2013 - Git - 获取远程分支的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我开始使用Visual Studio 2013和内置的使用Visual Studio Online的Git Team Explorer工具。我非常熟悉如何通过Git Shell来做到这一点,但似乎无法弄清楚如何通过VS 2013界面来做到这一点。

I am starting to use Visual Studio 2013 with the built-in Git Team Explorer tools using Visual Studio Online. I am very familiar with how to do this via the Git Shell but cannot seem to figure out how to do this via the VS 2013 interface.

我试图拉远程分支在本地,我无法这样做。通过命令行,我会这样做:

I am trying to pull a remote branch locally and am unable to do so. Via command line, I would do:

git fetch -a
git checkout <branchName>

我的工作流程是创建一个跟踪远程分支的本地分支;但是,下拉列表中的远程分支列表不完整。我该如何执行这个模仿 git fetch -a

I understand the workflow is to create a local branch that tracks the remote branch; however, my remote branch list in the dropdown is not complete. How do I perform this action which mimics git fetch -a?

的动作。下面是一张图片:

Below is a picture:

推荐答案

相当于使用Visual Studio 2013从Git团队资源管理器工具获取 git fetch ,您必须:

To perform the equivalent of git fetch from the Git Team Explorer tools with Visual Studio 2013, you have to:


  1. 转到 未定义提交 标签

  2. 切换到具有远程跟踪功能的分支(我总是使用master)

  1. Go to the Unsynced Commits tab
  2. Switch to a branch that has remote tracking (I always use master)
  3. Click Fetch under the Incoming Commits section

现在,您的远程分支列表将是最新的,您可以创建一个新分支来跟踪 origin / dev 分行

Now, your remote branch list will be up to date and you can create a new branch that tracks the origin/dev branch

< img src =https://i.stac k.imgur.com/XYc6r.pngalt =在这里输入图片描述>

这篇关于Visual Studio 2013 - Git - 获取远程分支的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆