header
header Register : : Login header
header
divider
menuleft
menuright
submenu
left
May 13

Written by: Tobias
5/13/2008 5:10 PM

In this blog, I cover features in PowerShell Plus. Feature #5: History tracking

I dont know about you, but I use command history a lot. It's just handy to press ArrowUp and get back my previous commands. Unfortunately, consoles generally seem to be a bit forgetful, and once you close powershell, all your history is gone. Of course you could export and re-import history using the PowerShell cmdlets, but that won't bring back the true console history and the ability to walk back your previous commands with the arrow keys. Bummer.

In PowerShell+, that's better. When you close and re-open PowerShell+, all your history is still there. Cool, eh? What's even better, PS+ automatically streamlines your history, too, so when you close PS+, it only remembers unique commands, and it won't remember commands that resulted in an error.

You can actually see all this magic when you press the transcript/Command History button. There you go and get a pretty good overview of your last commands. Wait, there's more!

The list entries are color-coded: green entries worked, red ones threw an exception. You can double-click a command to execute it again. And when you right-click a command, you get a context menu where you can load the command(s) into the editor, to the clipboard, and you can toggle the option to remove duplicate commands from the list.

Just in case you didnt like the history preservation, there's of course a setting to turn it off:

$psplus.ShowPSPSettings(4)

Enjoy!

Don't know PS+ yet? Go grab it: http://www.powershell.com/download/psp1.zip. Unzip, run. It's as easy as that. And it's free for non-commercial use. Enjoy!

Hungry for more? The latest (non-public) build is always available here: http://www.powershell.com/download/psp1new.zip. And the change log with the latest additions is available here: http://www.powershell.com/mantis/changelog_page.php.

Tags:
 

[August 25th, 2008] Check the home page regarding PowerShell related news from a brand new sponsor: Idera

Blogs
  
Search Blogs
  
Archives
  
right
   
footer Sponsored by Quest Software • SAPIEN Technologies • ShellTools, LLC • Microsoft Windows Server 2008 footer
footer