Skip to content

Commit c963751

Browse files
committed
added production mode to gulp
1 parent a8ec325 commit c963751

File tree

2 files changed

+7
-0
lines changed

2 files changed

+7
-0
lines changed

gulpfile.js

+6
Original file line numberDiff line numberDiff line change
@@ -22,13 +22,19 @@ const fs = require("fs");
2222
const jasmine = require('gulp-jasmine');
2323
const reporter = require("jasmine-spec-reporter");
2424
const benchmark = require('gulp-benchmark');
25+
const gutil = require('gulp-util');
2526

2627
let cli = commandLineArgs([
2728
{name: 'production', alias: 'p', type: Boolean, defaultOption: false}
2829
]);
2930

3031
let options = cli.parse();
3132

33+
if (options.production === true) {
34+
process.env.NODE_ENV = 'production';
35+
gutil.log("running in production mode");
36+
}
37+
3238
let sassGlob = "./sass/everything.scss";
3339
let tsGlob = "./src/**/*.@(ts|tsx)";
3440

package.json

+1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
"classnames": "^2.2.3",
99
"enzyme": "^2.2.0",
1010
"gulp-benchmark": "^1.1.1",
11+
"gulp-util": "^3.0.7",
1112
"jsdom": "^8.2.0",
1213
"microtime": "^2.0.0",
1314
"react": "^0.14.7",

0 commit comments

Comments
 (0)