a better way to clone the environment
resolve paths relative to __dirname so we don't depend on the cwd