From 863d43f5038cd3b660c2f5160cd56124fa09427b Mon Sep 17 00:00:00 2001 From: Noah Loomans Date: Tue, 6 Dec 2016 15:25:53 +0100 Subject: improved build system --- gulpfile.js | 14 -------------- package.json | 13 ++++--------- 2 files changed, 4 insertions(+), 23 deletions(-) delete mode 100644 gulpfile.js diff --git a/gulpfile.js b/gulpfile.js deleted file mode 100644 index bb38213..0000000 --- a/gulpfile.js +++ /dev/null @@ -1,14 +0,0 @@ -const gulp = require('gulp') -const fs = require('fs') -const browserify = require('browserify') - -gulp.task('scripts', function () { - browserify({ entries: './public/javascripts/main.js', debug: true }) - .transform('babelify', {presets: ['es2015']}) - .bundle() - .pipe(fs.createWriteStream('./public/javascripts/bundle.js')) -}) - -gulp.task('scripts:watch', function () { - return gulp.watch(['./public/javascripts/**/*.js', '!./public/javascripts/bundle.js'], ['scripts']) -}) diff --git a/package.json b/package.json index c831f7c..2fa3650 100644 --- a/package.json +++ b/package.json @@ -5,7 +5,9 @@ "private": true, "scripts": { "start": "node ./bin/www", - "setup": "npm install && bower install" + "setup": "npm install && bower install", + "build-dev": "browserify -d -t [ babelify --presets [ es2015 ] ] -e ./public/javascripts/main.js > ./public/javascripts/bundle.js", + "build": "browserify -t [ babelify --presets [ es2015 ] ] -e ./public/javascripts/bundle.js | uglifyjs > ./public/javascripts/bundle.js" }, "dependencies": { "bluebird": "^3.4.6", @@ -31,14 +33,7 @@ "babelify": "^7.3.0", "bower": "^1.7.9", "browserify": "^13.1.0", - "gulp": "^3.9.1", - "gulp-babel": "^6.1.2", - "gulp-browserify": "^0.5.1", - "vinyl-source-stream": "^1.1.0" - }, - "engine": { - "node": "*", - "npm": "*" + "gulp": "^3.9.1" }, "author": "Noah Loomans ", "license": "MIT", -- cgit v1.1