Private Extension Galleries for the Enterprise

Visual Studio Blog

In Visual Studio 2010, we introduced a feature called the Extension Manager – a new dialog that connects to the Microsoft Visual Studio Gallery to help a customer easily select and install extensions to Visual Studio from right inside the IDE.

image 

Since then, enterprise customers have frequently asked us to provide a way for Visual Studio to connect to a customer-managed website that contains a private collection of Visual Studio extensions. Today I’m excited to announce a new feature available in the Developer Preview version of VS that does just that, and offers you the same smooth, simple download, install, and update experience that you’ve seen when connected to the public Visual Studio Gallery. 

Configuring a private gallery

In the Extension Manager panel of the Tools/Options page, you can now add a URL to the Extension Repositories list that points to the server where your private gallery lives. Visual Studio expects to find an atom feed at this endpoint that describes the extensions available on your gallery.

image

Using your gallery

The next time you open the Extension Manager Online panel, you’ll see your gallery listed after the two public ones (Visual Studio Gallery and Samples Gallery).

image

Install looks exactly like it does for the public galleries:

image

Creating the gallery

On a web server, or on your local or remote file system, create a root directory for your gallery, and add sub-directories for each category in your collection. (In the illustration below, there are two categories: Project X and Project W.)

image

Place each VSIX file in the folder that corresponds to its category. Then it’s time to create the atom feed.

For this preview version, you’ll create the feed by hand. We’ll make some tools available to automate that process soon. Here is a sample feed, with the element values you’ll need to edit highlighted:

<?xml version=”1.0″ encoding=”utf-8″?>
<feed xmlns=”http://www.w3.org/2005/Atom”>
  <title type=”text”></title>
  <id>uuid:874a62b3-c36c-4443-aeb9-498e4c6e589d;id=1</id>
  <updated>2011-09-02T01:58:50Z</updated>
  <entry>
    <id>MessageInspector.Acme Corp..6b64a54c-93b9-4f0c-a962-71ba1c23c1d8</id>
    <title type=”text”>MessageInspector</title>
    <summary type=”text”>Visualizes message exchanges for Project W</summary>
    <published>2011-09-01T18:51:00-07:00</published>
    <updated>2011-09-01T18:57:18-07:00</updated>
    <author>
      <name>Acme Corp.</name>
    </author>
    <category term=”ProjectW Tools” />
    <content type=”application/octet-stream” src=”ProjectW Tools/MessageInspector.vsix” />
    <Vsix xmlns:xsi=”http://www.w3.org/2001/XMLSchema-instance” xmlns:xsd=”http://www.w3.org/2001/XMLSchema” xmlns=”http://schemas.microsoft.com/developer/vsx-syndication-schema/2010″>
      <Id>MessageInspector.Acme Corp..6b64a54c-93b9-4f0c-a962-71ba1c23c1d8</Id>
      <Version>1.0</Version>
      <References />
    </Vsix>
  </entry>
  <entry>
    <id>DataWarehousingTools.Acme Corp..496be56f-595e-4a50-b02f-5d3da630b7b6</id>
    <title type=”text”>DataWarehousingTools</title>
    <summary type=”text”>Data warehousing tools for Project X. (Internal use only.)</summary>
    <published>2011-09-01T18:51:28-07:00</published>
    <updated>2011-09-01T18:57:27-07:00</updated>
    <author>
      <name>Acme Corp.</name>
    </author>
    <category term=”ProjectX Tools” />
    <content type=”application/octet-stream” src=”ProjectX Tools/DataWarehousingTools.vsix” />
    <Vsix xmlns:xsi=”http://www.w3.org/2001/XMLSchema-instance” xmlns:xsd=”http://www.w3.org/2001/XMLSchema” xmlns=”http://schemas.microsoft.com/developer/vsx-syndication-schema/2010″>
      <Id>DataWarehousingTools.Acme Corp..496be56f-595e-4a50-b02f-5d3da630b7b6</Id>
      <Version>1.0</Version>
      <References />
    </Vsix>
  </entry>
</feed>

Values highlighted in yellow are taken right from the VSIX Manifest. Those highlighted in green describe how they appear in your gallery:

  • The term= attribute contains the category name as it will appear in Extension Manager.
  • The src= attribute contains the path to the VSIX file from the gallery root.

Updating

To publish an update, all you need to do is replace the old VSIX file with the new one, and put the Version value from the new VSIX manifest in the corresponding <Version> element in the feed.

<Id>DataWarehousingTools.Acme Corp..496be56f-595e-4a50-b02f-5d3da630b7b6</Id>
<Version>1.1</Version>

Then when your users open Extension Manager they’ll see the new version in the Update panel.

image

I’ll be blogging about tools to automate the feed generation as soon as we can make them available. In the meantime, try out the feature in the Visual Studio 11 Developer Preview and let us know what you think!

Gary Horen
Program Manager
Visual Studio Platform

0 comments

Discussion is closed.

Feedback usabilla icon