Powershell Function Header


The Powershell ISE may not be your favorite editor because of its limitations (long to start, has issues with high-consuming parallel workflows). However its snippets you can insert with the CTRL+J shortcut may be worthwhile to have a look at. One is particularly interesting: the powershell function header template. powershell-ise-snippet-list

The function (advanced) has every syntax you can put in the comments and as decorations around parameters when creating new functions. Copying and pasting them in your favorite text editor can save time when editing a powershell function header.

Here is by the way a slightly modified version of the function header so every parameter has all the decorations you can then just erase from to get down to what you want:

 

Leave a comment

Your email address will not be published. Required fields are marked *