Modifications to allow running on Windows

-Several changes to replace Unix commands and functionality