Make RunCommands Windows compatible

Emulate the same behavior on windows Systems that you would expect on a linux machine in regards to running command piped via stdin. On Windows, commands are piped to powershell.