git 取消绑定解决方案或项目 VS 2017 的源代码管理

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/45995442/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-09-19 12:53:28  来源:igfitidea点击:

Unbind Source Control for Solution or Project VS 2017

gitvisual-studio

提问by Cassova

Is there a way in Visual Studio 2017 to unbind a solution or project from source control? I can only find answers to this question for older versions which suggest going into File > Source Controlhowever it appears the Source Controloption has been removed in this version.

Visual Studio 2017 中是否有办法从源代码管理中解除绑定解决方案或项目?我只能为旧版本找到这个问题的答案,这些答案建议进入文件> 源代码管理,但似乎此版本中的源代码管理选项已被删除。

For older versions:

对于旧版本:

2010,2008,2005

2010、2008、2005

回答by Ignotus

In VS2017 (checked in versions 15.8.9 & 15.9.10) and VS2019 (16.5.4), goto:

在 VS2017(在 15.8.9 和 15.9.10 版本中检查)和 VS2019 (16.5.4) 中,转到:

Tools / Options / Source Control / Plug-in Selection

工具/选项/源代码控制/插件选择

In combo-box "Current source control plug-in:", change to "None" and click OK.

在组合框“当前源代码控制插件:”中,更改为“无”并单击“确定”。

The project will close; just reopen it and that's all...

该项目将关闭;重新打开它,仅此而已...

enter image description here

在此处输入图片说明

To reach the Plug-in Selection section in Options, you can also use the search box; just type "Plug-in" and click in "Source control -> Plug-in Selection". In combo-box "Current source control plug-in:", change to "None" and click OK.

要访问选项中的插件选择部分,您还可以使用搜索框;只需键入“插件”并单击“源代码控制-> 插件选择”。在组合框“当前源代码控制插件:”中,更改为“无”并单击“确定”。

enter image description here

在此处输入图片说明

回答by Naimish Mungara

just remove all .git base files from project root folder and sub folder, after that restart solution and project you will get git free project

只需从项目根文件夹和子文件夹中删除所有 .git 基本文件,重启解决方案和项目后,您将获得 git free 项目

回答by Cassova

It seems the only way to do this is manually removing files. This answer worked for me:

似乎唯一的方法是手动删除文件。这个答案对我有用:

Remove .git* files and folders

删除 .git* 文件和文件夹

回答by DSLuminary

In Visual Studio 2017, open a connected project or solution then select:

在 Visual Studio 2017 中,打开连接的项目或解决方案,然后选择:

  1. File
  2. Source Control
  3. Advanced
  4. Change Source Control
  5. Click Unbindon the project or solution of your choice.
  1. 文件
  2. 源代码管理
  3. 先进的
  4. 更改源代码管理
  5. 在您选择的项目或解决方案上单击取消绑定