comparison gulpfile.js @ 605:cb92d6eca543

cm: Fix Gulp config.
author Ludovic Chabant <ludovic@chabant.com>
date Wed, 27 Jan 2016 22:46:06 -0800
parents 7e4e567377cd
children ccd328d0881f
comparison
equal deleted inserted replaced
604:13987668311c 605:cb92d6eca543
20 'bower_components/bootstrap-sass/assets/stylesheets', 20 'bower_components/bootstrap-sass/assets/stylesheets',
21 'bower_components/Ionicons/scss']})) 21 'bower_components/Ionicons/scss']}))
22 //.pipe(sourcemaps.write()) 22 //.pipe(sourcemaps.write())
23 .pipe(rename({suffix: '.min'})) 23 .pipe(rename({suffix: '.min'}))
24 .pipe(minify()) 24 .pipe(minify())
25 .pipe(gulp.dest('../foodtruck/static/css')); 25 .pipe(gulp.dest('foodtruck/static/css'));
26 }); 26 });
27 gulp.task('sass:watch', function() { 27 gulp.task('sass:watch', function() {
28 return gulp.watch('foodtruckui/assets/sass/**/*.scss', ['sass']); 28 return gulp.watch('foodtruckui/assets/sass/**/*.scss', ['sass']);
29 }); 29 });
30 30
34 'bower_components/jquery/dist/jquery.js', 34 'bower_components/jquery/dist/jquery.js',
35 'bower_components/bootstrap-sass/assets/javascripts/bootstrap/alert.js', 35 'bower_components/bootstrap-sass/assets/javascripts/bootstrap/alert.js',
36 'bower_components/bootstrap-sass/assets/javascripts/bootstrap/button.js', 36 'bower_components/bootstrap-sass/assets/javascripts/bootstrap/button.js',
37 'bower_components/bootstrap-sass/assets/javascripts/bootstrap/collapse.js', 37 'bower_components/bootstrap-sass/assets/javascripts/bootstrap/collapse.js',
38 'bower_components/bootstrap-sass/assets/javascripts/bootstrap/dropdown.js', 38 'bower_components/bootstrap-sass/assets/javascripts/bootstrap/dropdown.js',
39 'bower_components/bootstrap-sass/assets/javascripts/bootstrap/modal.js',
39 'bower_components/bootstrap-sass/assets/javascripts/bootstrap/tooltip.js', 40 'bower_components/bootstrap-sass/assets/javascripts/bootstrap/tooltip.js',
40 'bower_components/bootstrap-sass/assets/javascripts/bootstrap/transition.js', 41 'bower_components/bootstrap-sass/assets/javascripts/bootstrap/transition.js',
41 'foodtruckui/assets/js/**/*.js' 42 'foodtruckui/assets/js/**/*.js'
42 ]) 43 ])
43 .pipe(sourcemaps.init()) 44 .pipe(sourcemaps.init())
44 .pipe(concat('foodtruck.js')) 45 .pipe(concat('foodtruck.js'))
45 .pipe(sourcemaps.write()) 46 .pipe(sourcemaps.write())
46 .pipe(rename({suffix: '.min'})) 47 .pipe(rename({suffix: '.min'}))
47 //.pipe(uglify()) 48 //.pipe(uglify())
48 .pipe(gulp.dest('../foodtruck/static/js')); 49 .pipe(gulp.dest('foodtruck/static/js'));
49 }); 50 });
50 gulp.task('js:watch', function() { 51 gulp.task('js:watch', function() {
51 return gulp.watch('foodtruckui/assets/js/**/*.js', ['js']); 52 return gulp.watch('foodtruckui/assets/js/**/*.js', ['js']);
52 }); 53 });
53 54
55 gulp.task('fonts', function() { 56 gulp.task('fonts', function() {
56 return gulp.src([ 57 return gulp.src([
57 'bower_components/bootstrap-sass/assets/fonts/bootstrap/*', 58 'bower_components/bootstrap-sass/assets/fonts/bootstrap/*',
58 'bower_components/Ionicons/fonts/*' 59 'bower_components/Ionicons/fonts/*'
59 ]) 60 ])
60 .pipe(gulp.dest('../foodtruck/static/fonts')); 61 .pipe(gulp.dest('foodtruck/static/fonts'));
61 }); 62 });
62 63
63 gulp.task('images', function() { 64 gulp.task('images', function() {
64 return gulp.src([ 65 return gulp.src([
65 'bower_components/bootstrap-sass/assets/images/*', 66 'bower_components/bootstrap-sass/assets/images/*',
66 'foodtruckui/assets/img/*' 67 'foodtruckui/assets/img/*'
67 ]) 68 ])
68 .pipe(gulp.dest('../foodtruck/static/img')); 69 .pipe(gulp.dest('foodtruck/static/img'));
69 }); 70 });
70 71
71 // Launch tasks 72 // Launch tasks
72 gulp.task('default', function() { 73 gulp.task('default', function() {
73 gulp.start(['sass', 'js', 'fonts', 'images']); 74 gulp.start(['sass', 'js', 'fonts', 'images']);