Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Visual Git 208 add-in fails to run under Windows 7/Visual Studio 2010

Sadly that's almost all the information I have at the moment.

The installer for Git Extensions 208 runs fine, the setup for Git Extensions validates fine, with green for all settings, Visual Git opens fine with Visual Studio 2008.

But, going into Visual Studio 2010 gives me a dialog:

The Add-in 'Visual Git' failed to load or caused an exception.
Would you like to remove this Add-in?
If you choose yes, the file it was loaded from,
'\\myFileServer\home\myUserName\Visual Studio 2010\Addins\GitPlugin.AddIn',
will be renamed.

Error Message: <Unknown Error>
Error number: 80131515

[Yes] [No]

Visual Git then fails to load.

Is the issue that the Visual Git files are being hosted from a file server? That's all I can think it might be...

Has anyone seen/solved this before?

EDIT: Before anyone asks, the title does not contain a typo of "2008". Git Extensions claims to work with VS2005/2008/2010. The fact that it's also at version 208 is a coincidence, as far as I know.

like image 459
Frosty840 Avatar asked Dec 13 '10 10:12

Frosty840


4 Answers

I ran into this problem, but found a solution.

I am running Visual Studio in a virtual machine on my MacBookPro. I'm using Parallels to run the virtual machine. Because of the way Parallels works my documents folder is actually technically a network share pointing back to MacOSX. And apparently Visual Studio 2010 doesn't like network shares for addins by default.

It looks like that is the problem the OP encountered as well looking at his error message.

To get it working, you have to add the loadFromRemoteSources element (see the MSDN reference) to the “C:\Program Files\Microsoft Visual Studio 10.0\Common7\IDE\devenv.exe.config”:

<configuration>
   <runtime>
      <loadFromRemoteSources enabled="true"/>
   </runtime>
</configuration>

I did that and it immediately loaded up and started working.

BTW, full attribution: I found the solution here.

like image 124
Max Schilling Avatar answered Nov 07 '22 20:11

Max Schilling


This didn't work for me until I looked at the comments here: http://msdn.microsoft.com/en-us/library/dd409252.aspx

Under Vista or Windows7 take care of thefile system Virtualization. Editing devenv.exe.config might result in creating a copy under

\Users{%UserName%}\AppData\local\VirtualStore\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\devenv.exe.config

leaving the original file untouched. This depends on your user settings. It might help to open "VS 2010 as administrator" (or another XML-Editor of your choice), edit devenv.exe.config, inserting the

tag, save the file and close. This will edit the original file, not the virtualized copy. Having done so referencing "remote" assemblies in your projects should work

like image 21
psfblair Avatar answered Nov 07 '22 20:11

psfblair


There is a known issue causing this. The work around can be found in the Git Extensions issue tracker: https://github.com/gitextensions/gitextensions/issues/80

like image 1
Henk Avatar answered Nov 07 '22 21:11

Henk


For anyone who can't get to Henk's link above: The issue (for future Googlers) is that the Git extension doesn't work if it's run from a UNC path (\\server\some\path) and has to be installed in a local directory. You can add a local directory via the Tools > Options > Environment > Add-In > Macro Security menu.

like image 1
David Moles Avatar answered Nov 07 '22 22:11

David Moles