Power Commands
PowerCommands is a set of useful extensions for the Visual Studio IDE, including Remove and Sort Usings, Copy Path and Open Command Prompt.
Power Commands
Power Commands is a set of useful extensions for the Visual Studio 2012 adding additional functionality to various areas of the IDE.
Individual power commands can be enabled or disabled from the Power Commands page in Tools -> Options in Visual Studio. It can be found under the Productivity Power Tools category. Most Power Commands are enabled by default. Below is a list of the commands included in Power Commands for Visual Studio 2012.
Format document on save
Enables formatting of tabs, spaces and other characters in a document to be saved. It is equivalent to using Format Document command under the Edit->Advanced menu. Disabled by default.
Remove and Sort Usings on save
Removes unused using statements and sorts the remaining using statements in the C# document being saved. Disabled by default.
Clear All Panes
Adds a button on the toolbar of the Output window that enables the user to clear all output panes at once.
Copy Path
Enables the file path of solutions, projects, folders and projects items to be copied from Solution Explorer via right-click menu.
Email CodeSnippet
Creates an email with the currently selected text. Available via right-click menu in the source code editor.
Insert Guid Attribute
Adds a Guid attribute to the selected class via right-click menu when the current selection is in class scope.
Show All Files
Shows the hidden files in all projects displayed in Solution Explorer when the solution node is selected. It enhances the Show All Files button, which would otherwise show the hidden files in the selected project node.
Collapse Projects
Collapses a project or projects in the Solution Explorer starting from the root selected node. This option resides in three different places on the Solution Explorer: Solution, Solution folders and Project nodes respectively.
Copy/Paste Class
Copies/Pastes a selected class entire content to/from the clipboard. When pasting a class, it is renamed to avoid a compilation error. It can be executed from a single project item or a project item with dependent sub items.
Copy/Paste References
Copies/Pastes one or more references to/from the clipboard. It can be executed from the references node, a single reference node or set of reference nodes.
Copy As Project Reference
Copies a project as a project reference to the clipboard. It can be executed from a project node.
Edit Project File
Opens the MSBuild project file for a selected project inside Visual Studio. It combines the existing Unload Project and Edit Project commands.
Open Containing Folder
Opens a Windows Explorer window pointing to the physical path of a selected item. It can be executed from a project item node.
Open Command Prompt
Opens a Visual Studio command prompt pointing to the physical path of a selected item. It can be executed from four different places: solution, project, folder and project item nodes respectively.
Unload Projects
Unloads all projects in a solution. This can be useful in MSBuild scenarios when multiple projects are being edited. This command can be executed from the solution node.
Reload Projects
Reloads all unloaded projects in a solution. It can be executed from the solution node.
Remove and Sort Usings
Removes and sort using statements for all classes given a project. It is useful, for example, in removing or organizing the using statements generated by a wizard. This command can be executed from a solution node or a single project node.
Extract Constant
Creates a constant definition statement for a selected text. Extracting a constant effectively names a literal value, which can improve readability. This command can be executed from the code editor by right-clicking selected text.
Clear Recent File List
Clears the Visual Studio recent file list. The Clear Recent File List command brings up a dialog that allows any or all recent files to be selected.
Clear Recent Project List
Clears the Visual Studio recent project list. The Clear Recent Project List command brings up a dialog that allows any or all recent projects to be selected.
Transform Templates
Executes a custom tool with associated text templates items. It can be executed from a DSL project node or a DSL folder node.
Close All
Closes all documents. It can be executed from a document tab.
Recently Closed Documents (Ctrl + Shift + Z)
Reopens a closed document, returning the cursor to its last position. Recently closed documents can be reopened through the Edit menu and clicking Undo Close or by using the Ctrl + Shift + Z shortcut.
You can view your recently closed documents by going to File > Recently Closed Documents menu.
Power Commands context menu
Power Command items have been into their own group. You still have all of the Power Commands intact, but we have just moved them into better locations within the Context Menu.
Previously part of Productivity Power Tools.