question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Gulp 4: gulp.single or at least hide <series/parallel> with single task

See original GitHub issue

I have a default task, and I want it to invoke the watch task when run. watch is in a separate file, so I can’t just reference the same function (assuming I had declared it separately).

The obvious answer would be to use gulp.series or gulp.parallel, but this is a bit strange, as it’s only a single task, and you end up with:

[21:42:37] +-- default
[21:42:37]   +-- <parallel>
[21:42:37]     +-- watch

Would you consider one of these options?

  1. Add the ability to do something like: gulp.task("default", gulp.single("watch")).
  2. At least hide <series/parallel> when it’s only a single task.

This is actually another issue that could be solved using dependencies (gulp.task("default", ["watch"]) – same as Gulp 3).

Issue Analytics

  • State:closed
  • Created 8 years ago
  • Reactions:1
  • Comments:15 (7 by maintainers)

github_iconTop GitHub Comments

3reactions
phatedcommented, Nov 25, 2015

We aren’t going to add an API just to reduce noise in this scenario and showing the series or parallel will allow for better traceability in complex compositions.

0reactions
phatedcommented, Jan 20, 2016

@jaydenseric possibly. Please open a new issue and give reproduction steps (gulpfile, etc).

Read more comments on GitHub >

github_iconTop Results From Across the Web

02 - Introduction to Gulp.js series and parallel tasks - Gulp 4
Gulpjs series where I go over the basic content:⦾ intro ⦾ gulp tasks ( series & parallel )⦾ compiling SCSS⦾ cleaning/minifying CSS⦾ ...
Read more >
How to run Gulp tasks sequentially one after the other
By default, gulp runs tasks simultaneously, unless they have explicit dependencies. This isn't very useful for tasks like clean , where you don't...
Read more >
series() - gulp.js
series ()#. Combines task functions and/or composed operations into larger operations that will be executed one after another, in sequential order.
Read more >
Moving from gulp 3 to 4 | Web Development - UConn Blogs
Task Functions · Start with the source files passed to gulp. · Capture and log any errors produced by the files (like when...
Read more >
Getting Started with Gulp.js - Semaphore Tutorial
What makes Gulp different from other task runners is that it uses Node streams; piping output from one task as an input to...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found