Visual Studio 2008 Powercommands free addin

written by Jason Short on Saturday, April 12 2008

Microsoft has released a new PowerCommands V1.1 tool for VS 2008.

This tool integrates within the IDE and gives you some very cool tools.  One of my favorites is the ability to right click a file and say "Open Containing Folder" - immediate access to an Explorer window to that file.  Makes it so much easier when you have to change permissions on a file that your source control left read only.

Take a look at the list of Power Commands site for complete explanations.  I am only going to list a few of my favorites.

Format document on save / Remove and Sort Usings on save
The Format document on save option formats the tabs, spaces, and so on of the document being saved. It is equivalent to pointing to the Edit menu, clicking Advanced, and then clicking Format Document. The Remove and sort usings option removes unused using statements and sorts the remaining using statements in the document being saved.

Note: The Remove and sort usings option is only available for C# documents.
Note: Format document on save and Remove and sort usings both are initially defaulted OFF.
 

I live with 3-4 command prompts open at any given time.  This tool alone means I can keep most of them closed until I need them and get to the correct spot immediately rather than CD'ing 12 paths that I can't keep in my memory.

Open Command Prompt
This command 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. 
 

Speaking of paths... The ability to copy out the path so you can open in Explorer, or your favorite FTP util is a big timesaver.

Copy Path
This command copies the full path of the currently selected item to the clipboard. It can be executed by right-clicking one of these nodes in the Solution Explorer:
The solution node; A project node; Any project item node; Any folder.

 

And who can live with email these days?  Stuck on a chunk of code, or perhaps need to email it as a response to a bug ticket?  Grab snippet, done.

Email CodeSnippet
To email the lines of text you select in the code editor, right-click anywhere in the editor and then click Email CodeSnippet.
 

And I always seem to close 1 more window that I meant to close when CTRL-F4 fever takes me.  Then I always get that blank look while trying to remember what was the name of that file again?

Undo Close
This command reopens a closed document , returning the cursor to its last position. To reopen the most recently closed document, point to the Edit menu, then click Undo Close. Alternately, you can use the CtrlShiftZ shortcut.
To reopen any other recently closed document, point to the View menu, click Other Windows, and then click Undo Close Window. The Undo Close window appears, typically next to the Output window. Double-click any document in the list to reopen it.
 

Summary

You can't live without this tool pack.  Trust me.  It is free (you can even get the source) and very easy to use.  One of the most useful addons to VS for me.

 

Links:
PowerCommands Download Site

Similar Posts

  1. devLINK 2007 – post show analysis
  2. The GC does not solve all memory leaks
  3. New way to distribute samples – Crazy idea?

Comments

  • Hans Nieuwenhuis on on 4.13.2008 at 9:56 PM

    Hans Nieuwenhuis avatar

    Hi Jason,

    Just to add: for cleaning up my 'using' statements, I use CodeRush or Refactor! of Developer Express. (One of those products contains this functionality, but I don't know exactly which one.)

    To format my source code any time I want, I use SourceFormatX of TextRush (www.textrush.com).

    But both products are not free...

    Hans

Comments are closed

Options:

Size

Colors