Replaced usage of the sh module with subprocess because sh does not work on windows

Note that I did not remove sh from the tests, as that'd be a bit more work.