Gulp: What is recommended way to execute node script

Created on 23 Jun 2014  路  3Comments  路  Source: gulpjs/gulp

After trying gulp-exec, gulp-shell and gulp-nodemon, I'm still puzzled how should I do simple node script execution with gulp.

$ node script.js

With gulp-nodemon execution is easy, but I don't need monitoring features (docs did not specify how to handle batch type of execution). gulp-shell and gulp-exec failed to execute node script when tested in Windows environment.

Most helpful comment

Note that gulp-shell is blacklisted, and typically require('child_process').exec is sufficient, removing the need for any plugins. See https://github.com/robrich/gulp-exec/blob/master/README.md#usage

All 3 comments

This is better asked on StackOverflow. Those gulp tasks should in theory work fine. Tag with gulp. Also make sure to include what you tried with some code ;)

@sindresorhus I understrand, this was completely wrong forum for this question.

If others stumble upon this, here is a solution:
https://github.com/sun-zheng-an/gulp-shell/issues/11

Note that gulp-shell is blacklisted, and typically require('child_process').exec is sufficient, removing the need for any plugins. See https://github.com/robrich/gulp-exec/blob/master/README.md#usage

Was this page helpful?
0 / 5 - 0 ratings

Related issues

emccorson picture emccorson  路  4Comments

fritzdenim picture fritzdenim  路  3Comments

ssteinerx picture ssteinerx  路  3Comments

cgc picture cgc  路  3Comments

aaronroberson picture aaronroberson  路  4Comments