Skip to content

Commit

Permalink
fix(hooks): only warn about missing tasks if they are missing
Browse files Browse the repository at this point in the history
  • Loading branch information
tlancina committed Mar 28, 2016
1 parent 33af80c commit 0ce5642
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions lib/cli.js
Original file line number Diff line number Diff line change
Expand Up @@ -150,9 +150,7 @@ function runWithGulp(argv, taskInstance){
return Q.fcall(taskInstance.run.bind(taskInstance), Cli, argv);
},
function(e){ //task error, let gulp handle it

// Warn if it's a v2 project and there isn't a build hook
if (/serve|build|run|emulate|upload/.test(cmdName) && argv.v2) {
if (e.missingTask && /serve|build|run|emulate|upload/.test(cmdName) && argv.v2) {
var taskName = (cmdName === 'serve') ? 'watch' : 'build';
console.warn('WARN: No \'' + beforeHook + '\' gulp task found!');

Expand Down

0 comments on commit 0ce5642

Please sign in to comment.