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

Reduce gulp task structure complexity #39

Closed
grieve opened this issue Apr 15, 2015 · 3 comments · Fixed by #56
Closed

Reduce gulp task structure complexity #39

grieve opened this issue Apr 15, 2015 · 3 comments · Fixed by #56

Comments

@grieve
Copy link
Contributor

grieve commented Apr 15, 2015

With the removal of alternate task runners, do each of the gulp tasks require the _common.js/gulp.js duo, wouldn't this be simpler to replace with one file per task.

run/tasks/scripts/
...  _common.js
...  gulp.js
run/tasks/styles/
...  _common.js
...  gulp.js

becomes

run/tasks/scripts.js
run/tasks/styles.js
@anthonyhastings
Copy link
Contributor

As discussed a while ago on Slack, the _common files do still serve a purpose of housing the tasks settings and keeping them isolated away from some of the bigger tasks. There's also some upcoming tasks such as a webpack task that will have more than one file associated with it, and the folder structure gives us the flexibility to group associated files together.

@grieve
Copy link
Contributor Author

grieve commented May 25, 2015

Could there be a middle ground here, where we rename the main file in each task from gulp.js to index.js? That way tasks are imported like require('./run/tasks/scripts') and that can be either a single file named scripts.js or a directory like scripts/index.js.

@anthonyhastings
Copy link
Contributor

Absolutely. The fact they're named gulp.js is a hang over from whenever we also had grunt.js files.

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

Successfully merging a pull request may close this issue.

2 participants