Skip to content
This repository has been archived by the owner on Sep 15, 2023. It is now read-only.

Setting additionalTasks means running "blendid" by itself won't enter watch mode #477

Closed
toolness opened this issue Jul 14, 2017 · 2 comments

Comments

@toolness
Copy link

I was following the instructions for additionalTasks and used code almost identical to the sample code in that section, but noticed that when I next ran blendid, while it did execute my custom tasks, it just exited after building the site, instead of starting a server and watching files for changes.

I think I was able to resolve this by adding 'watch' to the end of my additionalTasks.development.prebuild array, so it might be worth documenting in the readme.

@samhernandez
Copy link

I found that the example with empty arrays like

  development: {
    prebuild: ['createPngSprite'],
    postbuild: []
  },

where postbuild is empty, postbuild will halt the sequence of tasks. This is probably a function of gulpSequence. Blendid's task source looks like this.

gulpSequence('clean', prebuild, tasks.assetTasks, tasks.codeTasks, static, postbuild, 'watch', cb)

Removing the postbuild: [] line fixed it for me. postbuild: null and postbuild: false also work.

I also noticed in the gulpSequence usage docs that tasks within an array will run in parallel which is useful info as well.

@olets
Copy link
Contributor

olets commented May 28, 2019

Thanks for reporting! So sorry to be so slow. (And @toolness fwiw we love and have played with USWDS!)

The underlying [] issue is now #579. Closing this instance

@olets olets closed this as completed May 28, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

4 participants