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

Bring in new task system (bach) #355

Closed
4 tasks done
yocontra opened this issue Mar 20, 2014 · 63 comments
Closed
4 tasks done

Bring in new task system (bach) #355

yocontra opened this issue Mar 20, 2014 · 63 comments

Comments

@yocontra
Copy link
Member

  • Confirm 100% code coverage/test coverage on bach + child modules
  • Switch task system to bach (+ registry layer)
  • Update tests to use new task system
  • Update documentation folder

Does anyone care about being backwards compatible for a little bit or should we just rip this off like a bandaid?

@yocontra yocontra added this to the gulp 4 milestone Mar 20, 2014
@phated
Copy link
Member

phated commented Mar 20, 2014

Rip off the bandaid

@yocontra
Copy link
Member Author

👍

@irrg
Copy link

irrg commented Mar 20, 2014

Rip it off, for the sake of progress!

@tkellen
Copy link

tkellen commented Mar 20, 2014

Rip off the bandaid.

Bach looks great. Nice work @phated!

@OverZealous
Copy link

+1 for ripping off the band-aid.

Would it make sense to include a once() method in Bach as was being discussed on issue #347? Basically, a wrapper around an async method that guarantees it will only be run once.

@phated
Copy link
Member

phated commented Mar 20, 2014

@tkellen thanks, much appreciated

@sindresorhus
Copy link
Contributor

Rip it off.

@terinjokes
Copy link
Contributor

🙀

@jarvys
Copy link

jarvys commented Mar 23, 2014

Where can we see any progress?@robich's develop branch?

@tomasdev
Copy link

👍 ye-yeah

Yeah

@phated
Copy link
Member

phated commented Mar 26, 2014

probably better if you look at the blaine branch

@jasonrhodes
Copy link

@phated Looks like you're adding bach as a dependency of orchestrator right now—is the idea to make a gulp > orchestrator > bach dependency chain or gulp > bach?

@phated
Copy link
Member

phated commented Mar 27, 2014

@jasonrhodes gulp > orchestrator > bach + registry

@gaboesquivel
Copy link

+1 for .once() and...
image

@aeharding
Copy link

+1 for series/parallel/once.

I'm so excited! I have a huge gulpfile already (trying to move from Grunt), and this will make things easier and more reliable without having to spend a week getting comfy with orchestrator. The old way of doing series with dependencies wasn't good enough... It added a lot of repetitive code (spaghetti too to maintain/debug), increasing exponentially with each task you add...
yay

Rip it off! 🏥

@sindresorhus
Copy link
Contributor

What's the status on the new task system?

@pkozlowski-opensource
Copy link
Contributor

So, after playing with all the elements of the new gulp task system I must say that @phated did grand job here! For anyone interested in looking into what Gulp4 file might look like, here is a (working!) example:
https://github.com/pkozlowski-opensource/gulp4-poc/blob/master/gulpfile.js

From what I can see / understand there is one problem to solve: timing tasks. On top of this there are number of cleanups / corner-cases handling items to tackle but yeh, the main idea seems to be here and I must say I totally love it. Hope that introducing timing tasks won't turn things upside down!

I'm planning to switch to this POC in the real projects in the coming days / weeks and tackle all the issues I can find but again, the main building blocks seem to be in place :-)

@yocontra
Copy link
Member Author

@pkozlowski-opensource Yeah, @phated did do an awesome job with this concept. I have to say I'm enamored with bach, I just hope we can get it released ASAP before people get too cozy with the current system. Timing tasks is difficult, I think @phated had some ideas about that - the last time we spoke about it I think that logic was going to end up in the registry

@mlmorg
Copy link

mlmorg commented Aug 28, 2014

Would it be possible to peel apart task series/parallel functions in order to add/remove additional tasks to them with this new approach? In other words, can you alter a task function once it's been created?

For example, let's say an external library sets up a build task that has a default set of dependent tasks it runs in series (for example, clean, compile and deploy). Would it be possible to step into that task function and alter it to run a versioning task between the compile and deploy steps?

@phated
Copy link
Member

phated commented Sep 4, 2014

@mlmorg no, but composition based on environment, etc, should be easy with if/else, arrays and .apply.

@acdlite
Copy link

acdlite commented Oct 5, 2014

I'm late to this party, so forgive my naivety, as suspect what I'm about to suggest has already been considered and rejected... but why not just use promises? If we bring back gulp.run and have it return a promise, it seems to solve this issue entirely. Plus, there already popular many libraries that deal with async coordination — and with promises specifically, like bluebird and co — that it feels unnecessary for gulp to reinvent the wheel with its own API. I've been using promises to manage gulp tasks for a while and it works like a charm.

Am I missing a use case that promises don't solve?

@heikki
Copy link
Contributor

heikki commented Oct 5, 2014

@heikki
Copy link
Contributor

heikki commented Oct 5, 2014

I have no opinion related to promises.. just pointing to one place I remember same thing being mentioned :). On the other hand I'm happy with the current plan because it matches node-async syntax (series/parallel).

@coen-hyde
Copy link

I'm super excited about this new task system! Is the Gulp 4.0 branch ready for beta users?

@pikeas
Copy link

pikeas commented Oct 11, 2014

+1. I've followed the trail of breadcrumbs around Github, but I can't figure out where Bach and/or Gulp 4.0 are being worked on!

@phated
Copy link
Member

phated commented Oct 11, 2014

There is a branch called 4.0. I'd probably start there?

@alvint
Copy link

alvint commented Dec 2, 2014

While working on this, it would be nice if forward references to tasks were allowed. See #802.

P.S. - Great job so far!

@bnjmnt4n
Copy link

Any ETA for Gulp 4 to be released?

@yocontra
Copy link
Member Author

@D10 Trying to get it finished out before the end of 2014 but the holidays will probably have everyone preoccupied. I'm in the middle of moving our company across the country so I haven't had a ton of time to put towards closing out 4.0 issues

@bnjmnt4n
Copy link

@contra thanks for the update! You should probably tag this issue with gulp4.

@therebelrobot
Copy link

bump :) totally stoked for gulp 4

@yocontra
Copy link
Member Author

If anybody wants to help ship this faster: https://github.com/phated/undertaker/issues

@phated
Copy link
Member

phated commented Mar 22, 2015

Closing this because the 2 remaining items are separate issues now: #978 and #861

@phated phated closed this as completed Mar 22, 2015
@ilanbiala
Copy link

Can you update the original comment to get rid of the remaining items so that this issue seems complete?

@phated
Copy link
Member

phated commented Mar 22, 2015

@ilanbiala done

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

No branches or pull requests