1.2.5-0 • Published 8 years ago

ca-buildmodule v1.2.5-0

Weekly downloads
4
License
ISC
Repository
github
Last release
8 years ago

ConsumerAffairs Universal Build module

Of supreme buildocity

This module is to be installed atop any of our frontend modules that we want to automatically have our webpack/karma tasks available.

Default tasks and aliases are located inside of the tasks folder.

Usage

  • In the module you'd like to extend with this ensure you have gulp.
    • npm install --save-dev gulp
  • Install this module: npm install --save-dev ca-buildmodule
  • Create/modify your gulpfile.js to include default tasks, as shown below:
(function() {
    'use strict';

    var CABuild, gulp;
    gulp = require('gulp');
    // We need to instansiate the build module, and then hand it our current modules gulp binary
    // and any config we want to pass to customize this build
    CABuild = new (require('ca-buildmodule'))(gulp, { ... config ... });

    // You'll now have all of the default task
    // But dont let that stop you from creating some project-specify tasks as well
    gulp.task('do-other-stuff', function(){ ... });

}());
  • You can confirm that you have default tasks by running gulp --tasks. You should see quite the list.
  • Config items overwrite the defaults variable in this modules config file.
Update Notice

The main reason why this module was created was because the build tasks located within were getting manually cloned across projects, and maintaining fixes/improvements became nearly impossible.

This is written in a way to be both generic and customizable, but updates are likely to happen as technology changes and improvements are discovered. If you have a need for feature support please talk to your Team Lead and hopefully it can get worked in, and even more hopefully ... you'll be willing to contribute!

good day

Stylelint Notice

In order to run clear linting without packing use "gulp l" or "gulp lint"