How to remove/hide GitExtensions toolbar from Visual Studio?

可紊 提交于 2019-12-03 01:10:00

The Git Extension files are stored in your 'My Documents' folder in a "Visual Studio 2012" subfolder. Removing these files will make the toolbar disappear from within MSVC.

  1. Run Git Extensions uninstaller from Control Panel
  2. Click to 'Change' button
  3. Deselect "Visual Studio extension" feature

UPDATE

This should work with 2.48.04 and newer versions: right-click on a toolbar, uncheck GitExtensions, close all VS instances and start it again.

The location is correct, the file is called CurrentSettings.vssettings

I modified the line:

<add_toolbar Menu="{000D7B18-CDE4-49F0-B194-FE3E25BBF096}:00000002" 
 Name="GitExtensions" MenuType="toolbar" />

by adding Visibility="hide" FullScreen="hide"

Result:

<add_toolbar Menu="{000D7B18-CDE4-49F0-B194-FE3E25BBF096}:00000002" 
 Name="GitExtensions" MenuType="toolbar"
 Visibility="hide" FullScreen="hide"/>

Deleting or changing the settings files (C:\Users\UserName\Documents\Visual Studio 2012\Settings\CurrentSettings.vssettings) is only a temporary fix because Visual Studio recreates/overwrites this file each time you update a setting or close Visual Studio.

Using a team settings file doesn't work either because that file won't overwrite a parameter that's not in listed in the CurrentSettings.vssettigs file. And it won't be listed in the CurrentSettings.vssettigs file after you close Visual Studio and the file gets regenerated.

* I see 3 options *

1. Recompile GitExtensions with the modification noted here: https://github.com/gencer/gitextensions/commit/faef52e8191fde54ef9787f6f5156cf315ec9be5 This is not easy because the project includes a bunch of third party libraries that have to be installed and configured. Good Luck!

2. Use this .dll that was fixed by someone else. http://mirror.nienbo.com/git-extensions/patch_for_244/GitPlugin.dll After you download it, right click on it, select properties, and press the "unblock" button. Then copy it to C:\Users\UserName\Documents\Visual Studio 2012\Addins (overwriting the current file). This worked great for me.

3. Use a different git extension program.

Resetting all settings worked for me. Though, after that I had to set everything up from scratch.

If that's not a problem then go to visual studio TOOLS > Import and Export Settings...> Reset all Settings.

I think it takes effect after restarting visual studio.

The settings for the Visual Studio Git Extensions toolbar can be found in this file:

\Users{username}\Documents\Visual Studio 2012\Settings\CurrentSettings.vssettings

Search the file for the term GitExtensions to find the toolbar setting lines. There will likely be two lines, not necessarily next to each other:

<add_toolbar Menu="{000D7B18-CDE4-49F0-B194-FE3E25BBF096}:00000002" Name="GitExtensions" MenuType="toolbar"/>

<modify_toolbar Menu="{000D7B18-CDE4-49F0-B194-FE3E25BBF096}:00000002" Name="GitExtensions" Visibility="show" FullScreen="hide" Dock="top" Row="2" FloatRectangle="0,0,208,24" DockRectangle="0,0,208,24"/>

You'll want to modify the second of the two lines, since it will take precedence, and it already has the settings in it.

You can set the Visibility to "auto" to make it behave like other toolbars, or "hide" to just get rid of it. Set the Row to 1 if you want it to stick to the first row of toolbars.

Of course you'll have to do this with VS closed in order for it to work properly.

Please make sure you remove .git hidden folder from your solution folder. or any other .git file

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!