Skip to content

Commit

Permalink
Added grunt tasks autoloading
Browse files Browse the repository at this point in the history
  • Loading branch information
ravbetsky committed Feb 20, 2016
1 parent e0ed4ba commit f5bccc5
Showing 1 changed file with 4 additions and 9 deletions.
13 changes: 4 additions & 9 deletions Gruntfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,16 +11,11 @@ module.exports = function (grunt) {
path = require('path'),
themes = require('./dev/tools/grunt/configs/themes'),
configDir = './dev/tools/grunt/configs',
taskDir = './dev/tools/grunt/tasks';
tasks = grunt.file.expand('./dev/tools/grunt/tasks/*');

[
taskDir + '/mage-minify',
taskDir + '/deploy',
taskDir + '/black-list-generator',
taskDir + '/clean-black-list',
taskDir + '/static',
'time-grunt'
].forEach(function (task) {
tasks = _.map(tasks, function(task){ return task.replace('.js', '') });

tasks.forEach(function (task) {
require(task)(grunt);
});

Expand Down

0 comments on commit f5bccc5

Please sign in to comment.