Last active
August 14, 2017 17:34
-
-
Save TaylorAckley/6b13a96d62cdc677c310f5b120fe3a02 to your computer and use it in GitHub Desktop.
Gulp File - Modular Style
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"use strict"; | |
module.exports = function (gulp, _p, _o, s, d) { | |
if (!d) { | |
d = _o.global.outDir; | |
} | |
return function () { | |
gulp.src(s) | |
.pipe() | |
.dest(d); | |
}; | |
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"use strict"; | |
// Gulp -- The Gulp-Plugins library combs through the package.json and loads all the plugins that are in the form of 'gulp-*' for you into _p. | |
// Example: _p.concat() | More info: https://www.npmjs.com/package/gulp-load-plugins | |
const gulp = require('gulp'); | |
const _p = require('gulp-plugins'); | |
// Utilties | |
const chalk = require('chalk'); // Color output | |
const figures = require('figures'); // Report on file sizes. | |
const moment = require('moment'); | |
const _ = require('lodash'); | |
// Configuration files. | |
const _o = require('./gulp-modules/gulp.module.options'); | |
const _s = {}; | |
_s.js = require('./gulp-modules/gulp.module.sources-js'); | |
_s.css = require('./gulp-modules/gulp.module.sources-css'); | |
// Modules | |
function getTask(task) { | |
return require('./gulp-tasks/gulp.module.' + task)(gulp, _p, _o, _s); | |
} | |
// Default task | |
gulp.task('default', []); | |
// TFS Tasks | |
// Code Quality | |
gulp.task('lint:js'); | |
gulp.task('lint:css'); | |
// Unit Tests | |
// :( | |
// Compile tasks | |
gulp.task('compile:scss', getTask('compile-scss')); | |
// Bundle tasks | |
gulp.task('bundle:js'); | |
gulp.task('bundle:css'); | |
// Build tasks | |
// Cache Buster tasks | |
// Watch Tasks |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment