Karsten Heimrich

Qt Visual Studio Tools Insights

Published Friday January 27th, 2017
6 Comments on Qt Visual Studio Tools Insights
Posted in Dev Loop, integration, Labs, Qt, Random, Releases, Uncategorized, upgrading, Visual Studio, Windows

While working on the Qt Visual Studio tools, I had to think about how to locally perform and test the update process for extensions. As already known to most Visual Studio users, the IDE provides a way to setup your own private extension gallery. To do so, one has to open the Visual Studio Tools | Options Dialog and create a new Additional Extension Gallery under Environment | Extensions and Updates.

My initial try was to simply put the generated VSIX into a folder on the disk and point the URL field to this folder. After looking at the Tools | Extensions and Updates dialog, no update was highlighted for the tools. Because this was not as easy as I had thought, so some configuration file probably needed to be provided. A short search on the Internet led to the following article – there we go, it turned out that the configuration file is based on the Atom feed format.

Visual Studio uses an extended version of the Atom feed format consisting of two parts, the Header and the Entry. The header needs to be provided only once, while the entry can be repeated multiple times. Lets take a look at the header tags:

<title> The repository name.
<id> The unique id of the feed.
<updated> The date/time when the feed was updated.

Please note that even though these tags do not seem to be important for the desired functionality, it still makes sense to keep them.

The more interesting part is the Entry tag that describes the actual package you’re going to share. There seem to be a lot of optional tags as well, so I’m just going to describe the most important one. To force an update of your package, simply put an <Vsix> inside the entry tag. It must contain two other tags:

<id> The id of your VSIX.
<version> The version of the VSIX.

As soon as you increase the version number, even without rebuilding the VSIX, Visual Studio will present you with an update notice of your package. For a more advance description of the tags possible, follow this link. If you are looking for the minimum Atom feed file to start with, you can grab a copy of ours here.

So now one might ask, why did I write all that stuff? Well, while I was preparing the next Qt Visual Studio Tools release I scratched my head quite a bit on this topic. And just maybe – it might save some other developer’s day while doing a Visual Studio extension release. Last but not least, I am happy to announce the availability of an updated version of the Qt Visual Studio Tools with the following improvements:

  • Bug fixes
  • Making it faster
  • Using the new TextMate language files in Visual Studio 2015 SP3 for QML file and QMake project file syntax highlighting

The Qt Company has prepared convenient installers for the Qt Visual Studio Tools 2.1 release. You can download it from your Qt Account or from download.qt.io. They are also available from the Visual Studio Gallery for Visual Studio 2013 and Visual Studio 2015.

For any issues you may find with the release, please submit a detailed bug report to bugreports.qt.io (after checking for duplicates). You are also welcome to join the discussions in the Qt Project mailing lists, development forums and to contribute to Qt.

Do you like this? Share it
Share on LinkedInGoogle+Share on FacebookTweet about this on Twitter

Posted in Dev Loop, integration, Labs, Qt, Random, Releases, Uncategorized, upgrading, Visual Studio, Windows

6 comments

Asti says:

Thank you for improving visual studio integration.
In Vs2013 the ‘change qt version’ context menu doesn’t show a dialog as the old addin did. Is this a bug?

Karsten Heimrich Karsten Heimrich says:

I can’t find this option with the new tools. Could you please file a bug report here: https://bugreports.qt.io/browse/QTVSADDINBUG

Markus says:

It would be interesting to know which bugs were fixed for version 2.1 of VS Tools addon?
I can’t find anything related on the issue tracker: https://bugreports.qt.io/browse/QTVSADDINBUG

Karsten Heimrich Karsten Heimrich says:

Please follow this link.

Richard says:

I have Qt Visual Studio Tools 2.0.0, however Visual Studio 2015 is saying that there are no updates for it!

I so see v2.1.0 in the Gallery, so something has clearly made it to the Microsoft servers.

Karsten Heimrich Karsten Heimrich says:

Does it still not show the update? If so, please file a bug report here: https://bugreports.qt.io/browse/QTVSADDINBUG

Commenting closed.

Get started today with Qt Download now