OverZealous / run-sequence

Run a series of dependent gulp tasks in order
MIT License
962 stars 61 forks source link

Example does not work #78

Closed miguel-leon closed 8 years ago

miguel-leon commented 8 years ago

As of Gulp 3.9.1, the following example mentioned in the readme for this project does not work.

gulp.task('build', function(callback) {
runSequence('build-clean',
          ['build-scripts', 'build-styles'],
          'build-html',
          callback);
});

callback is not called and tasks are started but not finished. Found explanation here: https://github.com/robrich/orchestrator/issues/15

I know the readme mentions that using this is a hack, and it uses deprecated methods that may not work as expected. I'm just pointing it out because it may save some time to people following the example and expecting it to work.

OverZealous commented 8 years ago

Are your gulp tasks correctly set up? Because it they aren't configured correctly, then they never complete, and if they don't complete, the callback is never called.

runSequence still works for me without issue on 3.9.1

miguel-leon commented 8 years ago

I'm sorry for the promptly allegation. I tested a much more simplified version and it worked. Upon further analysis it seems it is having problems but with gulp-require-tasks and the tasks split into multiple files. Maybe it has something to do with orchestrator's runTask depending on Function.length.

If it's no longer pertinent. Please, remove the issue. And thanks for the quick response.

OverZealous commented 8 years ago

Ah, yeah, Gulp requires Function.length for the callback.

Glad you could figure it out!