如何在Visual Studio 2012中手动安装vsix(2011)?

问题描述:

我正在尝试在VS2012中安装vsix加载项.但是,看来此加载项仅适用于VS2010.

I'm trying to install a vsix add-in in VS2012. However it looks like this add-in is available only for VS2010.

有什么方法可以手动安装或强制其在2012年工作?

Is there any way to install it manually or to force it to work on 2012?

谢谢!

VSIX只是一个zip归档文件.解压缩它,找到文件extension.vsixmanifest.这是一个XML文件,将其打开.找到SupportedProducts部分.它应该如下所示:

VSIX is just a zip-archive. Unpack it, locate the file extension.vsixmanifest. This is an XML file, open it. Locate the section SupportedProducts. It should look like the following:

    <SupportedProducts>
        <VisualStudio Version="10.0">
            <Edition>Ultimate</Edition>
            <Edition>Premium</Edition>
            <Edition>Pro</Edition>
        </VisualStudio>
    </SupportedProducts>

复制并粘贴VisualStudio部分,并将粘贴的片段上的Version属性更新为11.0.

Copy-paste the VisualStudio section and update the Version attribute on the pasted fragment to 11.0.

将内容打包回zip归档文件中.确保存档具有VSIX扩展名.完成了.

Pack the contents back into a zip-archive. Make sure the archive have the VSIX extension. You're done.