changed to popen executing commands