'use strict';

(function () {

  var chalk = require('chalk');
  var fs = require('fs');

  var path = require('../../utils/path.js');

  var project = require('./utils/project.js');

  module.exports = function (options) {

    var dirname = process.cwd();

    var efesconfig = path.join(dirname, 'efesproject.json');

    if (!fs.existsSync(efesconfig)) {

      console.log(chalk.red('在当前目录下，未找到 efesproject.json 文件。'));
    } else {

      project(dirname, options);
    }
  };
})();