2016-03-20 2 views
1

Hallo Ich versuche, eine Aufgabe aus einer großen Schluck-Datei aus einem Tutorial auszuführen:A Gulp "Prozess mit Code 1 beendet"

var gulp = require('gulp'), 
    concat = require('gulp-concat'), 
    cssmin = require('gulp-cssmin'), 
    uglify = require('gulp-uglify'); 

var paths = { 
    webroot: "./wwwroot/" 
}; 

paths.bootstrapCss = "./bower_components/bootstrap/dist/css/bootstrap.css"; 
paths.sbAdminCss = "./bower_components/startbootstrap-sb-admin-2/dist/css/sb-admin-2.css"; 
paths.fontAwesomeCss = "./bower_components/font-awesome/css/font-awesome.css"; 
paths.morrisCss = "./bower_components/morrisjs/morris.css"; 

paths.jqueryJs = "./bower_components/jquery/dist/jquery.js"; 
paths.raphaelJs = "./bower_components/raphael/raphael.js"; 
paths.morrisJs = "./bower_components/morrisjs/morris.js"; 

paths.fonts = "./bower_components/font-awesome/fonts/*"; 

paths.jsDest = paths.webroot + "js"; 
paths.cssDest = paths.webroot + "css"; 
paths.fontDest = paths.webroot + "font"; 

gulp.task("min:js", function() { 
    return gulp.src([paths.jqueryJs, paths.raphaelJs, paths.morrisJs]) 
    .pipe(concat(paths.jsDest + "/min/site.min.js")) 
    .pipe(uglify()) 
    .pipe(gulp.dest(".")); 

}); 

gulp.task("copy.css", function() { 
    return gulp.src([paths.bootstrapCss, paths.sbAdminCss, paths.fontAwesomeCss]) 
    .pipe(gulp.dest(paths.cssDest)); 
}); 
gulp.task("copy:js", function() { 
    return gulp.src([paths.jqueryJs, paths.raphaelJs, paths.morrisJs]) 
    .pipe(gulp.dest(paths.jsDest)); 
}); 
gulp.task("copy:css", function() { 
    return gulp.src([paths.bootstrapCss, paths.sbAdminCss, paths.fontAwesomeCss]) 
    .pipe(gulp.dest(paths.cssDest)); 
}); 
gulp.task("copy:fonts", function() { 
    return gulp.src([paths.fonts]) 
    .pipe(gulp.dest(paths.fontDest)); 
}); 
gulp.task("min:css", function() { 
    return gulp.src([paths.bootstrapCss, paths.sbAdminCss, paths.fontAwesomeCss]) 
    .pipe(concat(paths.cssDest + "/min/site.min.css")) 
    .pipe(cssmin()) 
    .pipe(gulp.dest(".")); 
}); 
gulp.task("min", ["min:js", "min:css:"]); 
gulp.task("copy", ["copy:js", "copy:css", "copy:fonts"]); 

die Kopieraufgabe funktioniert, aber min returns "Prozess mit Code 1 beendet". Ich bin mir nicht sicher, was ich falsch geschrieben habe. Doppelüberprüften alles, aber ohne Erfolg

Antwort

0

Die "min" schluck Aufgaben hat eine ungültige Abhängigkeit

"min: CSS:" sollte "min: css". Beachten Sie das nachfolgende ":"