Browse Source

#3405 - formatting

pull/3321/head
Jack Lukic 9 years ago
parent
commit
db38c1723b
1 changed files with 10 additions and 9 deletions
  1. 19
      tasks/build/css.js

19
tasks/build/css.js

@ -28,6 +28,13 @@ var
tasks = require('../config/tasks'), tasks = require('../config/tasks'),
install = require('../config/project/install'), install = require('../config/project/install'),
maybeCallback = function() {
if (completeCount === 1) {
callback();
}
completeCount++;
},
// shorthand // shorthand
globs = config.globs, globs = config.globs,
assets = config.paths.assets, assets = config.paths.assets,
@ -59,12 +66,6 @@ module.exports = function(callback) {
return; return;
} }
function complete() {
if (++completeCount === 2) {
callback()
}
}
// unified css stream // unified css stream
stream = gulp.src(source.definitions + '/**/' + globs.components + '.less') stream = gulp.src(source.definitions + '/**/' + globs.components + '.less')
.pipe(plumber(settings.plumber.less)) .pipe(plumber(settings.plumber.less))
@ -90,7 +91,7 @@ module.exports = function(callback) {
.pipe(gulp.dest(output.uncompressed)) .pipe(gulp.dest(output.uncompressed))
.pipe(print(log.created)) .pipe(print(log.created))
.on('end', function() { .on('end', function() {
runSequence('package uncompressed css', complete);
runSequence('package uncompressed css', maybeCallback);
}) })
; ;
@ -105,8 +106,8 @@ module.exports = function(callback) {
.pipe(gulp.dest(output.compressed)) .pipe(gulp.dest(output.compressed))
.pipe(print(log.created)) .pipe(print(log.created))
.on('end', function() { .on('end', function() {
runSequence('package compressed css', complete);
runSequence('package compressed css', maybeCallback);
}) })
; ;
};
};
Loading…
Cancel
Save