Pipe or no pipe?
Many built-in cmdlets take input from the pipe, but alternatively let you specify an input with the -InputObject parameter. An example is the Get-Member cmdlet. I want to be able to do this with my own functions, but as far as I can tell, there is no built-in mechanism for…
Hashes and properties
I really like the way that PowerShell handily formats pipeline objects when displaying them in the console, eg get-childitem in a file system directory returns a collection of file objects and the output is like the old DOS dir command. Additionally, I really like the way that hashes behave like…
Making noises
There are twothree ways I know of to make noises in PowerShell. 1. Simple and most boring: use the internal speaker’s beep. write-host “`a`a`a” 2. Slightly better, use the .NET console beep. This plays A above middle C for one second. [console]::beep(440,1000) Both of the above are synchronous, ie, the…