Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Gulp.js conventions for tasks names

Are there any conventions for writing Gulpfiles, namespacing the tasks, structuring the config file etc?

Maybe there are some basic common-sense things that can be taken from Grunt world?

How do you deal with structuring the Gulpfile as if you were to quit your job and the next JS developer would come and intuitively understand how to build the project?

like image 819
zmii Avatar asked Jan 14 '16 08:01

zmii


1 Answers

So we finished up with grouping the names by phase, nesting subtasks under the names of the main phases.

Essentially we used strategy to copy conventions from build libraries of other languages (e.g. gradle) that were already in place, so build commands for all parts of our process would be the same and everybody could figure out what to

This resulted in:

build
...
build:compile
build:compile:less
...
test
test:unit
...
test:e2e
...
verify
...
release
release:copy
release:copy:fonts
like image 71
zmii Avatar answered Sep 21 '22 05:09

zmii