Skip to content

Instantly share code, notes, and snippets.

@jaggy
Last active August 29, 2015 14:10
Show Gist options
  • Save jaggy/fa698a236de917707d26 to your computer and use it in GitHub Desktop.
Save jaggy/fa698a236de917707d26 to your computer and use it in GitHub Desktop.
var gulp = require('gulp');
var stylus = require('gulp-stylus');
var jade = require('gulp-jade');
var jeet = require('jeet');
var rupture = require('rupture')
var path = {
views: './app/*.jade',
styles: './app/stylus/*.styl'
};
gulp.task('stylus', function () {
var options = {
compress: true,
use: [jeet(), rupture()]
};
gulp.src(path.styles)
.pipe(stylus(options))
.pipe(gulp.dest('./dist/css'));
});
gulp.task('watch', function () {
gulp.watch(path.views, ['jade']);
gulp.watch(path.styles, ['stylus']);
});
gulp.task('jade', function() {
gulp.src(path.views)
.pipe(jade())
.pipe(gulp.dest('./dist/'));
});
gulp.task('default', ['watch']);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment