Gulp - Visual Studio 2017 - MSB3073 The command "gulp postbuild" exited with code 1

Viewed 2687

In Visual Studio 2017 I am getting error MSB3073 The command "gulp postbuild" exited with code 1.

In my gulp file I have:

gulp.task('postbuild', function() {
   //...
});

On command line I get error when I try gulp loc:

C:\Users\User\AppData\Roaming\npm\node_modules\gulp\node_modules\semver\semver.js:281
throw new TypeError('Invalid Version: ' + version);
^

TypeError: Invalid Version: undefinedypeError('Invalid Version: ' + version);
1 Answers

In my case I just needed to add an environment variable NODE_PATH pointing to %AppData%\npm\node_modules

Related