How to: Run Multiple PowerShell Commands in a Single Line
So I looked for this on the internet and this giant blog post about process monitoring came up: http://blogs.technet.com/b/heyscriptingguy/archive/2010/10/20/use-powershell-to-combine-multiple-commands-for-ease-of-use.aspx.
Great, thanks for all the info, but the real answer to my question was ‘;’. Semicolon will run first one command and then the second command in sequence.
Sometimes it’s not the complicated answer I want, I just wanted to verify my theory that it might be semicolon before I told it to delete-item | dir c:\ or something stupid like that.
In: Programming · Tagged with: How-to, PowerShell, Troubleshooting