没有 Git for Windows 或 Github 扩展的 Visual Studio Git 源代码控制 [英] Visual Studio Git Source Control without Git for Windows or Github extension

查看:26
本文介绍了没有 Git for Windows 或 Github 扩展的 Visual Studio Git 源代码控制的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在团队资源管理器中,它提示我安装 3rd 方 git 工具,我不打算使用 Git 命令行,只是使用 Visual Studio 的本机 GUI 来克隆、拉取、提交、同步、合并和可能发出拉取请求.

那么我需要安装第 3 方 Git 命令提示工具(或 Github 扩展)吗?因为我已经安装了 2.10.1 并且没有注意到任何不同.如果我这样做我会得到什么,如果我不这样做我会失去什么,因为我想要一个干净的最小安装,并且那里的所有教程和文档都假设我必须安装它们.

解决方案

这可能符合

为您自己的命令行转义安装 git 客户端的最佳方法是在 Visual Studio 旁边安装 Git for Windows.如果你已经这样做了,你可以从 Visual Studio 中关闭提示

就个人而言,我喜欢通过解压缩最新的存档来安装"Git,例如:PortableGit-2.10.1-64-bit.7z.exe 我在任何地方想要.

In Team Explorer it prompts me to install 3rd party git tools, I don't intend on using the Git command line, just Visual Studio's native GUI to clone, pull, commit, sync, merge and maybe issue pull requests.

So do I need to install 3rd party Git command prompt tools (or Github extension)? because I already installed 2.10.1 and didn't notice anything different. What do I gain if I do and what do I lose if I don't, because I want a clean minimal installation, and all tutorials and docs out there assume I have to install them.

解决方案

This might be in line with the recent tweet from Edward Thomson (also on Stack Overflow):

I don't mind @VisualStudio removing libgit2 and moving to git, they had good reasons but the "it acts different" excuse it reads like FUD.

There are good reasons for them to move to git: maintaining libgit2 in VS was a nightmare. (I know! I used to do it!)

And why pay to hack on (or around) libgit2 when they employ a Git for Windows maintainer?

He is talking here about Johannes Schindelin, who got employed by Microsoft last August 2015, and who is releasing the Git for Windows editions.

Totally makes sense for them to move.

So until recently, Visual Studio did not use a third party Git client, but now it does, with Visual Studio 15 (as commented by jessehouwing, VS 2015 doesn't come with its own git.exe, it uses a library instead).

This is Visual Studio 15 Preview 5 (not Visual Studio 2015 which is v14.25123.xx)
See ycombinator.com:

Seems a shame the "15" team have given up on libgit2. Considering Microsoft have / are a contributor and presumably all contributing parties have the same goal (cross platform, feature parity etc) one has to wonder what's so bad with libgit2 it's been dropped in favour of shelling out to git.exe?

By dropping libgit2, they freed up some memory. Obviously the overall memory usage of VS and git is probably increased but VS teams are flogged until memory usage decreases because nobody will prioritize making it a 64 bit app


The OP asks:

as a matter of fact I'm using VS "15" Preview 5. So does that mean I'll need to install Git for Windows or is it already shipped with VS 15? And if so why does it still prompt me to install it? – Jonney Shih 3 mins ago

jessehouwing answers:

A very minimal version ships with Visual Studio. But it's not added to the path. So Visual Studio doesn't rely on you installing it.

It's installed here:

The best way to install a git client for your own command line escapades, is to install Git for Windows along side Visual Studio. If you've done so, you can dismiss the prompt from Visual Studio

Personally, I like to "install" Git simply by uncompressing the latest archive like: PortableGit-2.10.1-64-bit.7z.exe anywhere I want.

这篇关于没有 Git for Windows 或 Github 扩展的 Visual Studio Git 源代码控制的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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