Skip to content
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

support for gulp 4.0, also changed argument order #19

Closed
wants to merge 1 commit into from

Conversation

geekflyer
Copy link

  • new argument order: gulp.task([name, help, taskOptions, ] fn)

Hi, this was a quick n dirty modification to make it work with gulp 4.0. I don't expect you to merge this in right away - it's just for review / inspiration.
I won't work on this the next 3 weeks (too busy), but it works already for my purposes :-)

Limitations so far:

  • tests not adapted
  • no support for hiding tasks

* new argument order: gulp.task([name, help, taskOptions, ] fn)
@geekflyer geekflyer changed the title adapt code to work with gulp 4.0, also changed argument order support for gulp 4.0, also changed argument order Jan 9, 2015
@chmontgomery
Copy link
Owner

Thanks for this PR! If you find time to clean this up, I'll merge it as soon as gulp 4.0 is officially released

@thotjs
Copy link

thotjs commented Mar 2, 2015

Also wanted to note that 4.0 comes with a task list

gulp --tasks-simple

While not providing descriptions for tasks currently there have been discussions on it and it looks like they'll be made available in some form, definitely worth keeping an eye on. Hopefully it'll be something that's easy to tap into so you can still use aliases and hidden members but as of now it's still not implemented.

@thotjs
Copy link

thotjs commented Mar 4, 2015

Ended up having to roll something out for this functionality at work. When 4.0 comes out feel free to steal whatever you need from it, I may be able to jump back on to help once it is released but it depends on the work schedule.

Unfortunately it was faster for me just to rewrite the help module for 4.0 so it's not a pull request
https://github.com/adviceinteractivegroup/gulp-help-four

In case I can get back to helping support 4.0 would you be trying to maintain backwards compatibility in the task definitions so it can work across versions? the task API changes in 4.0 are fairly substantial.

Published on npm for now if anybody needs a temporary solution, I'll unpublish it once gulp 4 is out and gulp-help is ready to go with it

@chmontgomery
Copy link
Owner

@thotjs cool, thanks for the input.

I don't think maintaining backwards compatibility with gulp 3.x is necessary. Most gulp modules assume you're using the latest and greatest of everything. Plus, I'll be using proper semver on this package, so someone can just take a previous version that will work with gulp 3.x.

If anyone disagrees with my comments above just speak up.

@nmccready
Copy link

@chmontgomery you could also do what gulp does and add a 4.0 branch. Then have PRS submitted to that for gulp4 fixes. That way people can target their package.json to use the 4.0 branch.

@chmontgomery
Copy link
Owner

Just created a gulp4 branch. Feel free to update with some PRs. I'll do the same.

@yocontra
Copy link

Is this repo still needed with 4.0? We added a help command, curious to see where we still haven't met the needs of the community.

@chmontgomery
Copy link
Owner

@contra check out the gulp4 branch. It adds a few features not possible with --tasks or --tasks-simple requested by the community: documenting task flags, defining and documenting aliases, hiding tasks from the list and, last but not least, a pretty view of your tasks and descriptions (without --tasks's big tree view in the way):

screen shot 2015-09-28 at 3 36 30 am

I made the assumption you would not be interested in these kind of features in gulp core. If that's not the case, I'd be willing to make a PR to put these kind of features in gulp directly (perhaps under a --tasks-pretty?). We could discuss details.

@yocontra
Copy link

@chmontgomery We added the description field to gulp-cli recently. Feel free to open an issue over there and we can figure out what needs to be added!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants