I'm sure by now everyone has had a chance to play with the Windows 8 Developer Preview, I know I'm really excited about it, but moreover I'm very excited about the PowerShell ISE. I have moved away from using Notepad and Notepad++ for developing in PowerShell, to PowerShell ISE exclusively. With this new version of PowerShell ISE it's much more of an IDE than it was before, so I wanted to show a few things off.
$Host | Select-Object -Property Name, Version | ConvertTo-Html
Here you can see the whole application, and you will notice the command bar off to the right. This command bar has some nice features that will let you access commands from the various modules that are available on your machine very easily.
Here is a close-up of the command bar showing some of the modules that are available by default.
There are some buttons across the bottom Run, Insert, Copy and Hide. When you select a command from the list above and click Run the command is run and the output is displayed in the output pane. If you have a command selected and click Insert, that command is inserted into either the script pane or the command pane. Finally a selected command can be copied to the clipboard, or you can hide this bar altogether. Once a command is selected an additional button appears [?] with the command selected clicking this displays the help in a separate window that is not modal, but sits on top of everything. The screenshot below shows you the command bar with all the buttons clicked.
Auto-complete for many things in PowerShell have been around for a while, but if you miss the Intellisense features from like Visual Studio, it's now available within ISE, both in the script pane and the command pane. I know this can be really helpful as I'm used to using get-member to get a lot of this information as I'm working on a script.
Outlines! I really missed this feature when I moved from Notepad++ to PowerShell ISE. But in the following screenshot you can see that you now have collapsible outlines in PowerShell ISE, as well as something like code highlighting. You can see I have one of my functions collapsed, and have left the Process section of the code expanded. In the function below you can see that the help section of the function is highlighted. You can't see my mouse from this screenshot but it's hanging out in the border near line 66 where the help section begins.
Now that Windows Server 8 Beta and Windows 8 Consumer Preview are available, HELP for ISE tells us the following: Many new features and improvements have been added to Windows PowerShell ISE for Windows Server 8 Beta. Intellisense, an auto-completion assistance feature that is similar to that found in Visual Studio®, is now part of Windows PowerShell ISE. Intellisense displays clickable menus of matching cmdlets, parameters, parameter values, files, or folders as you type. Windows PowerShell ISE now supports add-on tools, which are Windows Presentation Foundation (WPF) controls that are added by using the object model. Add-on tools can be displayed in the console by using either a vertical or a horizontal pane. Multiple add-on tools in a pane are displayed as a tabbed control. A maximum of 20 user-defined add-on tools are allowed. You can also add or remove add-on tools that are produced by third parties. PowerShell ISE now automatically saves your open scripts every two minutes. To change the automatic saving interval, run the following in the console pane: $psise.Options.AutoSaveMinuteInterval. If Windows PowerShell ISE stops working, or if the operating system is restarted, after Windows PowerShell ISE is restarted, it recovers scripts that were open in the last session, even if the scripts were not saved. The separate command and output panes that were available in the first release of Windows PowerShell ISE have been combined into a single console pane. The console pane is similar in function and appearance to a typical Windows PowerShell console, but includes the following enhancements,
Other Windows PowerShell ISE editing features adapted from Visual Studio include:
.
Craig Lussier edited Revision 2. Comment: added "Windows Server 8 Beta" and "PowerShell v3" tag
tonysoper_MSFT edited Revision 1. Comment: + help text from Win8Beta
Ed Price - MSFT edited Original. Comment: Funny. =^)
Very good
Note: This article was written while referencing the Windows 8 Developer Preview. Contents subject to change when RTM'd.
I am absolutely blown away by the ISE in the Server 8 Beta - excellent work!
Loving v3.0 ISE <3