Skip to content

Instantly share code, notes, and snippets.

@gaspanik
Created February 7, 2014 00:07
Show Gist options
  • Save gaspanik/8855090 to your computer and use it in GitHub Desktop.
Save gaspanik/8855090 to your computer and use it in GitHub Desktop.
bootstrap3-sass-gulp.
// npm install gulp gulp-ruby-sass gulp-minify-css gulp-rename --save-dev
var gulp = require('gulp')
, sass = require('gulp-ruby-sass')
, minifycss = require('gulp-minify-css')
, rename = require('gulp-rename');
gulp.task('styles', function() {
return gulp.src('stylesheets/*.scss')
.pipe(sass({ style: 'expanded' }))
.pipe(gulp.dest('css'))
.pipe(rename({suffix: '.min'}))
.pipe(minifycss())
.pipe(gulp.dest('css'))
});
gulp.task('default', function() {
gulp.run('styles');
gulp.watch('stylesheets/**', function() {
gulp.run('styles');
});
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment