{"size": 1222, "ext": "js", "max_stars_repo_path": "src/main/frontend/gulpTask/default.js", "max_stars_repo_name": "m544498510/may-swim-app", "max_stars_repo_stars_event_min_datetime": "2016-03-27T14:56:01.000Z", "max_stars_repo_stars_event_max_datetime": "2019-04-08T09:34:12.000Z", "max_issues_repo_path": "src/main/frontend/gulpTask/default.js", "max_issues_repo_name": "m544498510/may-swim-app", "max_issues_repo_issues_event_min_datetime": null, "max_issues_repo_issues_event_max_datetime": null, "max_forks_repo_path": "src/main/frontend/gulpTask/default.js", "max_forks_repo_name": "m544498510/may-swim-app", "max_forks_repo_forks_event_min_datetime": null, "max_forks_repo_forks_event_max_datetime": null}
{"max_stars_count": 5, "max_issues_count": null, "max_forks_count": null, "avg_line_length": 33.9444444444, "max_line_length": 173, "alphanum_fraction": 0.5450081833}
/**
 *
 * @author :    Mei XinLin
 * @version :   1.0
 */
'use strict';

import gulp from 'gulp';
import runSequence from 'run-sequence';
import gutilsModule from 'gulp-load-utils';

const config = require(process.cwd() + '/config');

const gutils = gutilsModule(['colors', 'env', 'log']);


gulp.task('default', ()=> {
  /*
   * 用于获取输入的环境信息，并声明出来。（默认环境为development）
   * Run `gulp --production`
   */
  var type = gutils.env.production ? 'production' : 'development';
  if (type == 'development') {

    runSequence('clean', ['build:style', 'build:html', 'assets', 'lib', 'build:js'], 'dist', 'complete');
  } else if (type == 'production') {
    runSequence(['clean', 'unitTest'], ['build:js--production', 'build:style--production', 'min:img', 'move:nls', 'move:lib'], 'build:html--production', 'dist', 'complete');
  } else {
    gutils.log(gutils.colors.green('////////////////////////////////////'));
    gutils.log(gutils.colors.green('///                              ///'));
    gutils.log(gutils.colors.green('///   unknown development type   ///'));
    gutils.log(gutils.colors.green('///                              ///'));
    gutils.log(gutils.colors.green('////////////////////////////////////'));
  }
});
