How to tell PowerShell to wait for each command to end before starting the next?
Normally, for internal commands PowerShell does wait before starting the next command. One exception to this rule is external Windows subsystem based EXE. The first trick is to pipeline to Out-Null like so: PowerShell will wait until the Notepad.exe process has been exited before continuing. That is nifty but kind of subtle to pick up … Read more