By default the new Visual Studio 2010 SharePoint Developer Tools activate all Features from the package that is being deployed. While this is a great productivity feature when you need to quickly deploy something, it might be not the thing that you want while working with larger projects. The alternative available out of the box is not activating Features at all. Where does that takes us? I wrote about it previously. In my previous post I also suggested you could use Post-deployment Commands to activate the Features that you want. But wouldn’t it be just more convenient and intuitive if you could select Features that you want to activate during the deployment process? Proudly presenting: Mavention Activate Selected Features extension.
Mavention Activated Selected Features is a custom extension for the new Visual Studio 2010 SharePoint Developer Tools. Upon installation it adds the Select Features to activate… option to the project menu:
Clicking on that menu option will open a dialog which allows you to select Features that will be activated during the deployment process:
As you might have noticed the dialog shows not only the Features from the current project but all Features included in the current Package, which is exactly what you see in the Package Designer.
The Select Features dialog also allows you not only to select Features which will be activated during the deployment process, but also gives you the ability to set the order in which the Features are going to be activated. This might be important if you have for example a hidden Feature that depends on another Feature (Activation Dependencies are not supported for hidden Features).
Once you’re ready selecting the Features you can go and configuring the Deployment Configuration in Project Properties.
Mavention Activate Selected Features extension ships with a custom Deployment Step called Activate selected Features which activates Features just as configured in the previous step. In order to use it, you can either create a new Deployment Configuration or include the Activate selected Features step in your existing configuration.
Once you’re done with configuring the deployment process you can click Deploy from the project menu. In the output window you can see that only our two selected Features have been activated but also that they have been activated in exact same order as specified in the Select Features dialog.
Mavention Activate Selected Features is a free extension for the new Visual Studio 2010 SharePoint Developer Tools. This is the first – beta release of the extension. Both final release and the source code will be soon available as a part of the Community Kit for SharePoint: Development Tools Edition (CKS:DEV) toolset.
Download: Mavention Activate Selected Features from Visual Studio Gallery (51KB, VSIX)
Technorati Tags: SharePoint 2010,Visual Studio 2010