aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBen Beltran <ben@nsovocal.com>2016-03-27 23:33:46 -0600
committerBen Beltran <ben@nsovocal.com>2016-03-27 23:33:46 -0600
commit4c329508c3a6c56076c110cd4397fef0a219f7ce (patch)
tree1f5cbd73caac469f871abfbe72e3bce8e21fa7f9
parente936d6df77f8fe351fdde3fd9be829f9bc3aae97 (diff)
Adds the minifying process back
-rw-r--r--gulpfile.js7
-rw-r--r--package.json4
2 files changed, 10 insertions, 1 deletions
diff --git a/gulpfile.js b/gulpfile.js
index edd97d0..dcb689b 100644
--- a/gulpfile.js
+++ b/gulpfile.js
@@ -3,6 +3,8 @@
const Gulp = require('gulp');
const Babel = require('gulp-babel');
const Concat = require('gulp-concat');
+const Rename = require('gulp-rename');
+const Uglify = require('gulp-uglify');
Gulp.task('build', function() {
Gulp.src([
@@ -17,5 +19,10 @@ Gulp.task('build', function() {
presets: ['es2015']
}))
.pipe(Concat('serpentity.js'))
+ .pipe(Gulp.dest('dist'))
+ .pipe(Uglify())
+ .pipe(Rename({
+ suffix: '.min'
+ }))
.pipe(Gulp.dest('dist'));
});
diff --git a/package.json b/package.json
index 1e37373..0b50871 100644
--- a/package.json
+++ b/package.json
@@ -19,7 +19,9 @@
"babel-preset-es2015": "6.6.x",
"gulp": "3.9.x",
"gulp-babel": "6.1.x",
- "gulp-concat": "2.6.x"
+ "gulp-concat": "2.6.x",
+ "gulp-rename": "1.2.x",
+ "gulp-uglify": "1.5.x"
},
"engines": {
"node": ">= 4.0.0"