gulp-run icon indicating copy to clipboard operation
gulp-run copied to clipboard

gulp-run modifies global process.env polluting PATH

Open damonmaria opened this issue 7 years ago • 0 comments

On this line in command.js this.options.env is assigned process.env. Immediately afterwards this.options.env.PATH is modified. As process.env wasn't defensively copied when it was assigned this modifies the global process.env.PATH. So if you check process.env.PATH at the end of a gulp run it'll be full of other crap. And because of where this happens this problem applies just by defining your tasks, they don't even need to be run.

When defaulting options.env it should shallow copy process.env.

damonmaria avatar Jun 09 '17 07:06 damonmaria