Created
April 6, 2016 15:28
-
-
Save allmarkedup/e0cd2df5209c3ba7296a7e08fc936228 to your computer and use it in GitHub Desktop.
Run gulp tasks from within the Fractal interactive CLI interface
This file contains hidden or 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'; | |
const fractal = require('@frctl/fractal'); | |
const gulp = require('./gulpfile'); | |
fractal.command('gulp [task]', function(args, done){ | |
const task = args.task || 'default'; | |
this.console.notice(`Running gulp '${task}' task...`); | |
gulp.start(task, err => { | |
if (err) { | |
this.console.error(`There was a problem with the Gulp '${task}' task.`); | |
this.console.log(err); | |
} else { | |
this.console.success(`Gulp '${task}' task has run.`); | |
} | |
done(); | |
}); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment