-
Notifications
You must be signed in to change notification settings - Fork 4.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix build/watch for people importing tasks into their own gulpfile #2668
Conversation
This way, the gulp instance that is handed down to |
In case you're worried about idempotence of gulp-help, I tested it. You could do this var gulp = require('gulp-help')(require('gulp-help')(require('gulp-help')(require('gulp'))));
gulp.task('default', 'this is some default task', false, function(done) {
console.log('some task output');
done();
}); and still get the expected output
|
Edit: This is still required. |
How are you importing tasks, with two parameters or three? I think it might be a bit idiosyncratic to require other people who import the tasks to use |
The alternative is to remove the gulp-help argument from gulp.task from all files that get sourced by
As these come from files that are also sourced when running gulp from the semantic directory, removing the gulp-help argument from them would break running The nice thing about my PR is that users aren't forced to use gulp-help in their gulp file, if they don't want to. Though even when they to, it will still work. Negative side-effect: When users use gulp-help in their project, they also see all the semantic targets. |
I'll be evaluating this shortly.. hold tight |
I've tested this and it works as you say, using either gulp help or no gulp help in the imported |
fix build/watch for people importing tasks into their own gulpfile
I've created an example repository which I will include in docs to help people understand what to do. |
See #2653