Created
November 18, 2015 15:43
-
-
Save biwin/63fb08952e83bf69569d to your computer and use it in GitHub Desktop.
gulpfile to reload and compile sass files
This file contains 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
var gulp = require('gulp'); | |
var sass = require('gulp-sass'); | |
var livereload = require('gulp-livereload'); | |
gulp.task('sass', function () { | |
gulp.src('scss/*.scss') | |
.pipe(sass({outputStyle: 'compressed'})) | |
.pipe(gulp.dest('css')) | |
.pipe(livereload()); | |
}); | |
gulp.task('default', function() { | |
livereload.listen(); | |
gulp.watch(['*.html']).on('change', livereload.changed); | |
gulp.watch('scss/*.scss', ['sass']); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment