Added export
Fixed remove bug and switched to Popen
Remoced os.chdir in favor of Popen(cwd=...)