Last active
August 29, 2015 14:16
-
-
Save 8bitDesigner/6ee842ae2cc820aed3f7 to your computer and use it in GitHub Desktop.
Moving from Gulp to Make. Can't say I miss Gulp at all.
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') | |
, source = require('vinyl-source-stream') | |
, sass = require('gulp-sass') | |
, browserify = require('browserify') | |
, babelify = require('babelify') | |
gulp.task('build:js', function() { | |
return browserify('./app/public/jsx/app.jsx') | |
.transform(babelify) | |
.bundle() | |
.pipe(source('app.js')) | |
.pipe(gulp.dest('./app/public/js')) | |
}) | |
gulp.task('build:css', function () { | |
return gulp.src('./app/public/scss/**/*.scss') | |
.pipe(sass({ | |
includePaths: ['./node_modules/bootstrap-sass/assets/stylesheets'] | |
})) | |
.pipe(gulp.dest('./app/public/css')) | |
}); | |
gulp.task('default', ['build:js', 'build:css']) |
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
PATH := node_modules/.bin:$(PATH) | |
SHELL := /bin/bash | |
css := app/public/css/app.css | |
js := app/public/js/app.js | |
all: $(js) $(css) | |
clean: | |
rm -rf $(css) $(js) | |
$(js): app/public/jsx/app.jsx | |
browserify $< -t babelify -o $@ | |
$(css): app/public/scss/app.scss | |
sassc -I node_modules/bootstrap-sass/assets/stylesheets $< $@ | |
.PHONY: clean |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment