From 6041eab6d357c992b6d9a2301e71d7dd649814dc Mon Sep 17 00:00:00 2001 From: thinkholic Date: Thu, 26 Oct 2017 15:37:02 +0530 Subject: [PATCH] Add Prettier support --- .eslintrc | 10 +- bin/index.js | 4 +- lib/actions/artisan.js | 211 +++++++------- lib/actions/config.js | 34 ++- lib/actions/db.js | 4 +- lib/actions/index.js | 14 +- lib/actions/logs.js | 20 +- lib/actions/plugin.js | 40 +-- lib/actions/theme.js | 153 +++++----- lib/actions/utils.js | 16 +- lib/cli.js | 96 +++--- lib/env.js | 28 +- lib/promptSchema/config.js | 78 ++--- lib/promptSchema/index.js | 6 +- lib/promptSchema/installConfig.js | 26 +- lib/promptSchema/theme.js | 50 ++-- lib/updateNotifier.js | 4 +- package.json | 11 +- yarn.lock | 465 +++++++++++++++++++++++++++++- 19 files changed, 871 insertions(+), 399 deletions(-) diff --git a/.eslintrc b/.eslintrc index 26ca6fe..e5127e3 100644 --- a/.eslintrc +++ b/.eslintrc @@ -4,7 +4,7 @@ "es6": true, "node": true }, - "extends": "airbnb", + "extends": ["airbnb", "prettier"], "parser": "babel-eslint", "rules": { // code arrangement matter @@ -23,5 +23,13 @@ "max-len": [2, 100, 4], "import/prefer-default-export": 0 + }, + { + "plugins": [ + "prettier" + ], + "rules": { + "prettier/prettier": "error" } } +} diff --git a/bin/index.js b/bin/index.js index b413a00..a419e6a 100755 --- a/bin/index.js +++ b/bin/index.js @@ -1,4 +1,4 @@ #!/usr/bin/env node -require('../lib/cli'); -require('../lib/updateNotifier'); +require("../lib/cli"); +require("../lib/updateNotifier"); diff --git a/lib/actions/artisan.js b/lib/actions/artisan.js index 8dba061..4907516 100644 --- a/lib/actions/artisan.js +++ b/lib/actions/artisan.js @@ -1,17 +1,17 @@ /* eslint no-plusplus: 0, max-len: 0, no-shadow: 0, no-param-reassign: 0 */ -const wpCli = require('node-wp-cli'); -const shelljs = require('shelljs/shell'); -const inquirer = require('inquirer'); -const _ = require('lodash'); +const wpCli = require("node-wp-cli"); +const shelljs = require("shelljs/shell"); +const inquirer = require("inquirer"); +const _ = require("lodash"); -const Utils = require('./utils'); -const Logs = require('./logs'); -const Db = require('./db'); +const Utils = require("./utils"); +const Logs = require("./logs"); +const Db = require("./db"); -const env = require('../env'); -const pkg = require('../../package.json'); -const promptSchema = require('../promptSchema'); +const env = require("../env"); +const pkg = require("../../package.json"); +const promptSchema = require("../promptSchema"); // [TODO] // - Improve the commit/rollback function @@ -22,7 +22,7 @@ function rollback(path) { } function updateSchema(schema, config) { - schema.forEach((obj) => { + schema.forEach(obj => { if (config[obj.name]) { obj.default = config[obj.name]; } @@ -36,8 +36,8 @@ function initialize(path, config, options) { const workingDir = Utils.getWorkingDir(path); // show initializing message - Logs.show('project-init', { - type: 'Info', + Logs.show("project-init", { + type: "Info", message: null, params: { docRoot: `${workingDir}` @@ -48,7 +48,7 @@ function initialize(path, config, options) { const args = {}; if (options && options.force) args.force = true; - let serveCommand = '\twp serve'; // this will use in end of the file + let serveCommand = "\twp serve"; // this will use in end of the file args.path = env.defaults.installDir; if (path) { @@ -60,13 +60,13 @@ function initialize(path, config, options) { } // download wordpress-latest - wpCli.call('core download', args, (err, resp) => { + wpCli.call("core download", args, (err, resp) => { if (err) { - Logs.show('wordpress-fetching-failed', { - type: 'Error', + Logs.show("wordpress-fetching-failed", { + type: "Error", message: null, params: { - message: (err && err.message) ? err.message : '' + message: err && err.message ? err.message : "" } }); @@ -74,11 +74,11 @@ function initialize(path, config, options) { return; } - Logs.show('wordpress-fetching-success', { - type: 'Info', + Logs.show("wordpress-fetching-success", { + type: "Info", message: null, params: { - message: (resp && resp.message) ? resp.message : '' + message: resp && resp.message ? resp.message : "" } }); @@ -89,63 +89,64 @@ function initialize(path, config, options) { const configDefaults = JSON.parse( Utils.readFileSync( Utils.getTemplatePath(`defaults/${env.defaults.config}`), - 'utf-8' + "utf-8" ) ); _.merge(configDefaults, config); // create `site.json` - Utils.writeJSONSync( - `${workingDir}/${env.defaults.config}`, - configDefaults - ); + Utils.writeJSONSync(`${workingDir}/${env.defaults.config}`, configDefaults); // clean wordpress codebase const deleteList = env.deleteList; for (let i = 0; i < deleteList.length; i++) { - deleteList[i] = deleteList[i].replace('', `${workingDir}/${env.defaults.installDir}`); + deleteList[i] = deleteList[i].replace( + "", + `${workingDir}/${env.defaults.installDir}` + ); } Utils.forceUnlink(deleteList); // create `wp-config.php` Utils.writeFileSync( `${workingDir}/${env.defaults.installDir}/wp-config.php`, - Utils.getTemplatePath('wp-config.php'), + Utils.getTemplatePath("wp-config.php"), configDefaults ); // create `.gitignore` Utils.writeFileSync( `${workingDir}/.gitignore`, - Utils.getTemplatePath('.gitignore') + Utils.getTemplatePath(".gitignore") ); // create the databse - Db.create(config.db, (err) => { + Db.create(config.db, err => { if (err) { - Logs.show('create-database-failed', { - type: 'Error', + Logs.show("create-database-failed", { + type: "Error", message: null, params: { - message: (err && err.message) ? err.message : '' + message: err && err.message ? err.message : "" } }); // Ready for development. // yet, Database creation failed. - Logs.show('project-init-success', { - type: 'Info', + Logs.show("project-init-success", { + type: "Info", message: null, params: { siteName: config.site.name, docRoot: workingDir, - warnings: '\r\nSomething went wrong!\r\nYou need to update database settings manually.\r\n', + warnings: + "\r\nSomething went wrong!\r\nYou need to update database settings manually.\r\n", command: serveCommand } }); } else { - Logs.show('create-database-success', { - type: 'Info', + Logs.show("create-database-success", { + type: "Info", message: null, params: {} }); @@ -165,55 +166,56 @@ function initialize(path, config, options) { args.path = `${path}/${env.defaults.installDir}`; } - wpCli.call('core install', args, (err, resp) => { + wpCli.call("core install", args, (err, resp) => { if (err) { - Logs.show('wordpress-installing-failed', { - type: 'Error', + Logs.show("wordpress-installing-failed", { + type: "Error", message: null, params: { - message: (err && err.message) ? err.message : '' + message: err && err.message ? err.message : "" } }); return; } - Logs.show('wordpress-installing-success', { - type: 'Info', + Logs.show("wordpress-installing-success", { + type: "Info", message: null, params: { - message: (resp && resp.message) ? resp.message : '' + message: resp && resp.message ? resp.message : "" } }); // Ready for development // All initilizing steps are done. - Logs.show('project-init-success', { - type: 'Info', + Logs.show("project-init-success", { + type: "Info", message: null, params: { siteName: config.site.name, docRoot: workingDir, - warnings: '', + warnings: "", command: serveCommand } }); }); } else { - Logs.show('wordpress-installing-skipped', { - type: 'Warn', + Logs.show("wordpress-installing-skipped", { + type: "Warn", message: null, params: {} }); // Ready for development // Skipped WordPress instalaltion - Logs.show('project-init-success', { - type: 'Info', + Logs.show("project-init-success", { + type: "Info", message: null, params: { siteName: config.site.name, docRoot: workingDir, - warnings: '\r\nWordPress instalaltion yet to be complete.\r\nYou need to do it manually.\r\n', + warnings: + "\r\nWordPress instalaltion yet to be complete.\r\nYou need to do it manually.\r\n", command: serveCommand } }); @@ -226,7 +228,9 @@ function initialize(path, config, options) { module.exports = { isInitialized(path) { const workingDir = Utils.getWorkingDir(path); - const isConfigExists = Utils.isFileExists(`${workingDir}/${env.defaults.config}`); + const isConfigExists = Utils.isFileExists( + `${workingDir}/${env.defaults.config}` + ); if (isConfigExists) { return true; @@ -240,13 +244,13 @@ module.exports = { path = path .trim() .toLowerCase() - .replace(/[ .!@#$%^*()\\/?<>[\]{}&+=|;:"']/g, '-') - .replace(/(-)+/g, '-'); + .replace(/[ .!@#$%^*()\\/?<>[\]{}&+=|;:"']/g, "-") + .replace(/(-)+/g, "-"); } // welcome - Logs.show('welcome', { - type: 'Info', + Logs.show("welcome", { + type: "Info", message: null, params: { cliVersion: pkg.version, @@ -256,8 +260,8 @@ module.exports = { // check if already initialized a project if (this.isInitialized(path)) { - Logs.show('project-init-failed', { - type: 'Error', + Logs.show("project-init-failed", { + type: "Error", message: null, params: {} }); @@ -265,48 +269,48 @@ module.exports = { } // prompt for user inputs - Logs.show('prompt-site-config', { - type: 'Info', + Logs.show("prompt-site-config", { + type: "Info", message: null, params: {} }); - inquirer - .prompt(promptSchema.config) - .then((config) => { - // update configs. - const serverHost = (config.server.host) ? config.server.host : env.defaults.server.host; - const serverPort = (config.server.port) ? config.server.port : env.defaults.server.port; - config.site.url = `http://${serverHost}:${serverPort}`; - config.cliVersion = pkg.version; - - if (config.install.confirm) { - // prompt for user inputs - Logs.show('prompt-install-config', { - type: 'Info', - message: null, - params: {} - }); + inquirer.prompt(promptSchema.config).then(config => { + // update configs. + const serverHost = config.server.host + ? config.server.host + : env.defaults.server.host; + const serverPort = config.server.port + ? config.server.port + : env.defaults.server.port; + config.site.url = `http://${serverHost}:${serverPort}`; + config.cliVersion = pkg.version; + + if (config.install.confirm) { + // prompt for user inputs + Logs.show("prompt-install-config", { + type: "Info", + message: null, + params: {} + }); - inquirer - .prompt(updateSchema(promptSchema.installConfig, config)) - .then((installConfig) => { - _.merge(config, installConfig); - initialize(path, config, options); - } - ); - } else { - initialize(path, config, options); - } + inquirer + .prompt(updateSchema(promptSchema.installConfig, config)) + .then(installConfig => { + _.merge(config, installConfig); + initialize(path, config, options); + }); + } else { + initialize(path, config, options); } - ); + }); }, startServer(options) { // check if already initialized a project if (!this.isInitialized()) { - Logs.show('working-directory-invalid', { - type: 'Error', + Logs.show("working-directory-invalid", { + type: "Error", message: null, params: {} }); @@ -317,7 +321,9 @@ module.exports = { const workingDir = Utils.getWorkingDir(); // Grab the configurations - const config = JSON.parse(Utils.readFileSync(`${workingDir}/${env.defaults.config}`, 'utf-8')); + const config = JSON.parse( + Utils.readFileSync(`${workingDir}/${env.defaults.config}`, "utf-8") + ); const portToSet = options.port || config.server.port; // If the given port is different than whats in the config, update site.json with the new port @@ -331,20 +337,21 @@ module.exports = { // Check is installed or not before execute below commands. // Update the `siteurl` and `home` values in the wp_options table according to the new port. - const query = `UPDATE ${config.db.TBL_PREFIX}` + - "options SET option_value = '" + - `http://localhost:${portToSet}` + - "' WHERE option_name = 'home' OR option_name = 'siteurl';"; + const query = + `UPDATE ${config.db.TBL_PREFIX}` + + "options SET option_value = '" + + `http://localhost:${portToSet}` + + "' WHERE option_name = 'home' OR option_name = 'siteurl';"; - Db.queryExec(config.db, query, (err) => { + Db.queryExec(config.db, query, err => { if (err) { - Logs.show('server-install-script-not-run', { - type: 'Warn', + Logs.show("server-install-script-not-run", { + type: "Warn", message: null, params: { dateStarted: new Date(), IpPort: `http://${config.server.host}:${portToSet}`, - message: (err && err.message) ? err.message : '' + message: err && err.message ? err.message : "" } }); } @@ -356,8 +363,8 @@ module.exports = { }; // Show startup message - Logs.show('server-started', { - type: 'Log', + Logs.show("server-started", { + type: "Log", message: null, params }); diff --git a/lib/actions/config.js b/lib/actions/config.js index 470ecce..8618884 100644 --- a/lib/actions/config.js +++ b/lib/actions/config.js @@ -1,17 +1,17 @@ -const _ = require('lodash'); +const _ = require("lodash"); -const Utils = require('./utils'); -const Logs = require('./logs'); -const artisan = require('./artisan'); +const Utils = require("./utils"); +const Logs = require("./logs"); +const artisan = require("./artisan"); -const env = require('../env'); +const env = require("../env"); module.exports = { update(key, val) { // check if already initialized a project if (!artisan.isInitialized()) { - Logs.show('working-directory-invalid', { - type: 'Error', + Logs.show("working-directory-invalid", { + type: "Error", message: null, params: {} }); @@ -20,10 +20,10 @@ module.exports = { // check isAllow to update the key const allowUpdate = env.config.allowUpdate; - const isAllowed = (_.indexOf(allowUpdate, key) > -1); + const isAllowed = _.indexOf(allowUpdate, key) > -1; if (!isAllowed) { - Logs.show('config-update-invalid', { - type: 'Error', + Logs.show("config-update-invalid", { + type: "Error", message: null, params: {} }); @@ -31,8 +31,8 @@ module.exports = { } // logs - Logs.show('config-updating', { - type: 'Info', + Logs.show("config-updating", { + type: "Info", message: null, params: {} }); @@ -41,7 +41,9 @@ module.exports = { // Here, only allowing to update Databse configs. // Need to improve this [PIORITY] - const config = JSON.parse(Utils.readFileSync(`./${env.defaults.config}`, 'utf-8')); + const config = JSON.parse( + Utils.readFileSync(`./${env.defaults.config}`, "utf-8") + ); config.db[key] = val; // update `site.json` @@ -56,7 +58,7 @@ module.exports = { // update `wp-config.php` Utils.writeFileSync( `./${env.defaults.installDir}/wp-config.php`, - Utils.getTemplatePath('wp-config.php'), + Utils.getTemplatePath("wp-config.php"), newConfig ); @@ -64,8 +66,8 @@ module.exports = { // Update the database fields in site already installed // logs - Logs.show('config-update-success', { - type: 'Info', + Logs.show("config-update-success", { + type: "Info", message: null, params: {} }); diff --git a/lib/actions/db.js b/lib/actions/db.js index 566fc55..1474243 100644 --- a/lib/actions/db.js +++ b/lib/actions/db.js @@ -1,4 +1,4 @@ -const mysql = require('mysql'); +const mysql = require("mysql"); module.exports = { create(config, cb) { @@ -51,7 +51,7 @@ module.exports = { dbConn.connect(); // Run the query and if success, run the callback - dbConn.query(query, (err) => { + dbConn.query(query, err => { if (err) { cb(err, null); } else { diff --git a/lib/actions/index.js b/lib/actions/index.js index d54b155..ebacbe8 100644 --- a/lib/actions/index.js +++ b/lib/actions/index.js @@ -1,10 +1,10 @@ -const artisan = require('./artisan'); -const config = require('./config'); -const db = require('./db'); -const logs = require('./logs'); -const plugin = require('./plugin'); -const theme = require('./theme'); -const utils = require('./utils'); +const artisan = require("./artisan"); +const config = require("./config"); +const db = require("./db"); +const logs = require("./logs"); +const plugin = require("./plugin"); +const theme = require("./theme"); +const utils = require("./utils"); module.exports = { artisan, diff --git a/lib/actions/logs.js b/lib/actions/logs.js index 130ee0f..c3d7f9e 100644 --- a/lib/actions/logs.js +++ b/lib/actions/logs.js @@ -1,17 +1,15 @@ /* eslint complexity: 0 */ -const _ = require('lodash'); -const chalk = require('chalk'); +const _ = require("lodash"); +const chalk = require("chalk"); -const Utils = require('./utils'); +const Utils = require("./utils"); const logger = console; module.exports = { show(id, log = null) { - const method = (log && log.type) ? - log.type.toLowerCase() : - 'log'; + const method = log && log.type ? log.type.toLowerCase() : "log"; let message; @@ -29,10 +27,12 @@ module.exports = { // Add basic colors to errors and warnings if (log && log.type) { - if (log.type === 'Error') { - message = `${chalk.bold.underline.red('Error:')} ${chalk.red(message)}`; - } else if (log.type === 'Warn') { - message = `${chalk.bold.underline.yellow('Warning:')} ${chalk.yellow(message)}`; + if (log.type === "Error") { + message = `${chalk.bold.underline.red("Error:")} ${chalk.red(message)}`; + } else if (log.type === "Warn") { + message = `${chalk.bold.underline.yellow("Warning:")} ${chalk.yellow( + message + )}`; } } diff --git a/lib/actions/plugin.js b/lib/actions/plugin.js index 0859d1f..1267309 100644 --- a/lib/actions/plugin.js +++ b/lib/actions/plugin.js @@ -1,9 +1,9 @@ -const wpCli = require('node-wp-cli'); +const wpCli = require("node-wp-cli"); -const Logs = require('./logs'); -const artisan = require('./artisan'); +const Logs = require("./logs"); +const artisan = require("./artisan"); -const env = require('../env'); +const env = require("../env"); // [TODO] // Here, we can provide number of options to update/remove plugins @@ -16,8 +16,8 @@ module.exports = { add(pluginName) { // check if already initialized a project if (!artisan.isInitialized()) { - Logs.show('working-directory-invalid', { - type: 'Error', + Logs.show("working-directory-invalid", { + type: "Error", message: null, params: {} }); @@ -25,8 +25,8 @@ module.exports = { } // logs - Logs.show('plugin-installing', { - type: 'Info', + Logs.show("plugin-installing", { + type: "Info", message: null, params: {} }); @@ -39,8 +39,8 @@ module.exports = { // install the plugin wpCli.call(`plugin install ${pluginName}`, args, (err, resp) => { if (err) { - Logs.show('plugin-installing-failed', { - type: 'Error', + Logs.show("plugin-installing-failed", { + type: "Error", message: null, params: { message: resp.message @@ -49,8 +49,8 @@ module.exports = { return; } - Logs.show('plugin-installing-success', { - type: 'Info', + Logs.show("plugin-installing-success", { + type: "Info", message: null, params: {} }); @@ -60,8 +60,8 @@ module.exports = { remove(pluginName) { // check if already initialized a project if (!artisan.isInitialized()) { - Logs.show('working-directory-invalid', { - type: 'Error', + Logs.show("working-directory-invalid", { + type: "Error", message: null, params: {} }); @@ -69,8 +69,8 @@ module.exports = { } // logs - Logs.show('plugin-uninstalling', { - type: 'Info', + Logs.show("plugin-uninstalling", { + type: "Info", message: null, params: {} }); @@ -83,8 +83,8 @@ module.exports = { // install the plugin wpCli.call(`plugin uninstall ${pluginName}`, args, (err, resp) => { if (err) { - Logs.show('plugin-uninstalling-failed', { - type: 'Error', + Logs.show("plugin-uninstalling-failed", { + type: "Error", message: null, params: { message: resp.message @@ -93,8 +93,8 @@ module.exports = { return; } - Logs.show('plugin-uninstalling-success', { - type: 'Info', + Logs.show("plugin-uninstalling-success", { + type: "Info", message: null, params: {} }); diff --git a/lib/actions/theme.js b/lib/actions/theme.js index d3e2a33..710e8c9 100644 --- a/lib/actions/theme.js +++ b/lib/actions/theme.js @@ -1,20 +1,20 @@ /* eslint max-len: 0 */ -const inquirer = require('inquirer'); +const inquirer = require("inquirer"); -const Utils = require('./utils'); -const Logs = require('./logs'); -const artisan = require('./artisan'); +const Utils = require("./utils"); +const Logs = require("./logs"); +const artisan = require("./artisan"); -const promptSchema = require('../promptSchema'); -const env = require('../env'); +const promptSchema = require("../promptSchema"); +const env = require("../env"); module.exports = { init(options = null) { // check if already initialized a project if (!artisan.isInitialized()) { - Logs.show('working-directory-invalid', { - type: 'Error', + Logs.show("working-directory-invalid", { + type: "Error", message: null, params: {} }); @@ -23,88 +23,93 @@ module.exports = { if (options && options.clean) { // Show warning - Logs.show('theme-clean-dir', { - type: 'Warn', + Logs.show("theme-clean-dir", { + type: "Warn", message: null, params: {} }); } // Logs - Logs.show('prompt-theme-config', { - type: 'Info', + Logs.show("prompt-theme-config", { + type: "Info", message: null, params: {} }); - inquirer - .prompt(promptSchema.theme) - .then((config) => { - const themeName = config.themeName - .trim() - .toLowerCase() - .replace(/[ .!@#$%^*()\\/?<>[\]{}&+=|;:"']/g, '-') - .replace(/(-)+/g, '-'); - - // Init. - Logs.show('theme-init', { - type: 'Info', - message: null, - params: { - themeName - } - }); + inquirer.prompt(promptSchema.theme).then(config => { + const themeName = config.themeName + .trim() + .toLowerCase() + .replace(/[ .!@#$%^*()\\/?<>[\]{}&+=|;:"']/g, "-") + .replace(/(-)+/g, "-"); - // [TODO] - // Improve the logic here. - // --clean=true - if (options && options.clean) { - const dirList = Utils.getDirContents( - `${Utils.getWorkingDir()}/${env.defaults.installDir}/wp-content/themes/` - ); - // Exclude `index.php` - dirList.splice(dirList.indexOf('index.php'), 1); - - // set directory paths - dirList.forEach((dir, index) => { - dirList[index] = `${Utils.getWorkingDir()}/${env.defaults.installDir}/wp-content/themes/${dir}`; - }); - - // Clean the theme directory - Utils.forceUnlink(dirList); + // Init. + Logs.show("theme-init", { + type: "Info", + message: null, + params: { + themeName } + }); - // create theme directory - Utils.mkdirSync(`${Utils.getWorkingDir()}/${env.defaults.installDir}/wp-content/themes/${themeName}`); - - // add `style.css` - Utils.writeFileSync( - `${Utils.getWorkingDir()}/${env.defaults.installDir}/wp-content/themes/${themeName}/style.css`, - Utils.getTemplatePath('theme/style.css'), - config - ); - - // add `index.php` - Utils.writeFileSync( - `${Utils.getWorkingDir()}/${env.defaults.installDir}/wp-content/themes/${themeName}/index.php`, - Utils.getTemplatePath('theme/index.php'), - null - ); - - // copy `screenshot.png` - Utils.copyFileSync( - `${Utils.getResourcePath(env.resources.screenshot)}`, - `./${env.defaults.installDir}/wp-content/themes/${themeName}/` + // [TODO] + // Improve the logic here. + // --clean=true + if (options && options.clean) { + const dirList = Utils.getDirContents( + `${Utils.getWorkingDir()}/${env.defaults + .installDir}/wp-content/themes/` ); + // Exclude `index.php` + dirList.splice(dirList.indexOf("index.php"), 1); - Logs.show('theme-init-success', { - type: 'Info', - message: null, - params: { - themeDir: `${Utils.getWorkingDir()}/${env.defaults.installDir}/wp-content/themes/${themeName}/` - } + // set directory paths + dirList.forEach((dir, index) => { + dirList[index] = `${Utils.getWorkingDir()}/${env.defaults + .installDir}/wp-content/themes/${dir}`; }); + + // Clean the theme directory + Utils.forceUnlink(dirList); } - ); + + // create theme directory + Utils.mkdirSync( + `${Utils.getWorkingDir()}/${env.defaults + .installDir}/wp-content/themes/${themeName}` + ); + + // add `style.css` + Utils.writeFileSync( + `${Utils.getWorkingDir()}/${env.defaults + .installDir}/wp-content/themes/${themeName}/style.css`, + Utils.getTemplatePath("theme/style.css"), + config + ); + + // add `index.php` + Utils.writeFileSync( + `${Utils.getWorkingDir()}/${env.defaults + .installDir}/wp-content/themes/${themeName}/index.php`, + Utils.getTemplatePath("theme/index.php"), + null + ); + + // copy `screenshot.png` + Utils.copyFileSync( + `${Utils.getResourcePath(env.resources.screenshot)}`, + `./${env.defaults.installDir}/wp-content/themes/${themeName}/` + ); + + Logs.show("theme-init-success", { + type: "Info", + message: null, + params: { + themeDir: `${Utils.getWorkingDir()}/${env.defaults + .installDir}/wp-content/themes/${themeName}/` + } + }); + }); } }; diff --git a/lib/actions/utils.js b/lib/actions/utils.js index 4ab4076..a4e589a 100644 --- a/lib/actions/utils.js +++ b/lib/actions/utils.js @@ -1,7 +1,7 @@ -const shelljs = require('shelljs/shell'); -const fs = require('fs'); -const fsExtra = require('fs-extra'); -const _ = require('lodash'); +const shelljs = require("shelljs/shell"); +const fs = require("fs"); +const fsExtra = require("fs-extra"); +const _ = require("lodash"); const Utils = { getWorkingDir(path = null) { @@ -30,7 +30,7 @@ const Utils = { try { fs.lstatSync(fp); } catch (err) { - if (err.code === 'ENOENT') { + if (err.code === "ENOENT") { return false; } throw err; @@ -54,7 +54,7 @@ const Utils = { }, copyFileSync(srcFp, targetFp) { - shelljs.cp('-R', srcFp, targetFp); + shelljs.cp("-R", srcFp, targetFp); }, mkdirSync(path) { @@ -66,10 +66,10 @@ const Utils = { }, forceUnlink(fp) { - if (typeof fp !== 'object') { + if (typeof fp !== "object") { return; } - shelljs.rm('-rf', fp); + shelljs.rm("-rf", fp); } }; diff --git a/lib/cli.js b/lib/cli.js index a64620b..6495008 100644 --- a/lib/cli.js +++ b/lib/cli.js @@ -1,49 +1,46 @@ -const program = require('commander'); +const program = require("commander"); -const actions = require('./actions'); -const pkg = require('../package.json'); +const actions = require("./actions"); +const pkg = require("../package.json"); -program - .version(pkg.version); +program.version(pkg.version); // program: init program - .command('init [dir]') - .option('-f, --force', 'Overwrites existing files, if have.') - .description('wp init [dir] -f') + .command("init [dir]") + .option("-f, --force", "Overwrites existing files, if have.") + .description("wp init [dir] -f") .action((dir, options) => { actions.artisan.initialize(dir, options); - } -); + }); // program: config program - .command('config ') - .option('-u, --update', 'Update site configurations') - .description('wp config -u ') + .command("config ") + .option("-u, --update", "Update site configurations") + .description("wp config -u ") .action((key, val, options) => { // update if (options.update) { actions.config.update(key, val); } - } -); + }); // program: plugin program - .command('plugin ') - .description('wp plugin ') + .command("plugin ") + .description("wp plugin ") .action((action, pluginName) => { switch (action) { - case 'add': + case "add": actions.plugin.add(pluginName); break; - case 'remove': + case "remove": actions.plugin.remove(pluginName); break; default: - actions.logs.show('plugin-invalid-option', { - type: 'Error', + actions.logs.show("plugin-invalid-option", { + type: "Error", message: null, params: { opt: action @@ -51,22 +48,21 @@ program }); break; } - } -); + }); // program: theme program - .command('theme ') - .option('-c, --clean', 'Clean the theme dierctory') - .description('wp theme ') + .command("theme ") + .option("-c, --clean", "Clean the theme dierctory") + .description("wp theme ") .action((action, options) => { switch (action) { - case 'init': + case "init": actions.theme.init(options); break; default: - actions.logs.show('theme-invalid-option', { - type: 'Error', + actions.logs.show("theme-invalid-option", { + type: "Error", message: null, params: { opt: action @@ -74,33 +70,31 @@ program }); break; } - } -); + }); // program: serve program - .command('serve') - .alias('s') - .option('-p, --port [value]', 'Port to listen on (instead of the default 8080).') - .description('wp serve') - .action((options) => { + .command("serve") + .alias("s") + .option( + "-p, --port [value]", + "Port to listen on (instead of the default 8080)." + ) + .description("wp serve") + .action(options => { actions.artisan.startServer(options); - } -); + }); // program: [anything else] -program - .command('*') - .action((env) => { - // show error message - actions.logs.show('invalid-command', { - type: 'Error', - message: null, - params: { - env - } - }); - } -); +program.command("*").action(env => { + // show error message + actions.logs.show("invalid-command", { + type: "Error", + message: null, + params: { + env + } + }); +}); program.parse(process.argv); diff --git a/lib/env.js b/lib/env.js index 2999c02..ba5d1c4 100644 --- a/lib/env.js +++ b/lib/env.js @@ -1,28 +1,28 @@ module.exports = { defaults: { - installDir: 'site', - config: 'site.json', + installDir: "site", + config: "site.json", server: { - host: 'localhost', - port: '8080' + host: "localhost", + port: "8080" } }, config: { allowUpdate: [ - 'MYSQL_HOST', - 'MYSQL_PORT', - 'MYSQL_USER', - 'MYSQL_PASSWORD', - 'NAME' + "MYSQL_HOST", + "MYSQL_PORT", + "MYSQL_USER", + "MYSQL_PASSWORD", + "NAME" ] }, resources: { - screenshot: 'screenshot.png' + screenshot: "screenshot.png" }, deleteList: [ - '/wp-config-sample.php', - '/readme.html', - '/wp-content/plugins/akismet', - '/wp-content/plugins/hello.php' + "/wp-config-sample.php", + "/readme.html", + "/wp-content/plugins/akismet", + "/wp-content/plugins/hello.php" ] }; diff --git a/lib/promptSchema/config.js b/lib/promptSchema/config.js index b0cfba5..de9eb1e 100644 --- a/lib/promptSchema/config.js +++ b/lib/promptSchema/config.js @@ -1,66 +1,66 @@ module.exports = [ { - type: 'input', - name: 'site.name', - message: 'Enter the site name' + type: "input", + name: "site.name", + message: "Enter the site name" }, { - type: 'input', - name: 'db.MYSQL_HOST', - message: 'MYSQL Database Host', - default: '127.0.0.1' + type: "input", + name: "db.MYSQL_HOST", + message: "MYSQL Database Host", + default: "127.0.0.1" }, { - type: 'input', - name: 'db.MYSQL_PORT', - message: 'MYSQL Database Port', - default: '3306' + type: "input", + name: "db.MYSQL_PORT", + message: "MYSQL Database Port", + default: "3306" }, { - type: 'input', - name: 'db.MYSQL_USER', - message: 'MYSQL Database User', - default: 'root' + type: "input", + name: "db.MYSQL_USER", + message: "MYSQL Database User", + default: "root" }, { - type: 'password', - name: 'db.MYSQL_PASSWORD', - message: 'MYSQL Database Password', - default: '' + type: "password", + name: "db.MYSQL_PASSWORD", + message: "MYSQL Database Password", + default: "" }, { - type: 'input', - name: 'db.NAME', - message: 'MYSQL Database Name', + type: "input", + name: "db.NAME", + message: "MYSQL Database Name", validate(value) { - if (!value || value.trim() === '') { - return 'Please must provide a database name here!'; + if (!value || value.trim() === "") { + return "Please must provide a database name here!"; } return true; } }, { - type: 'input', - name: 'db.TBL_PREFIX', - message: 'MYSQL Database Table Prefix', - default: 'wp_' + type: "input", + name: "db.TBL_PREFIX", + message: "MYSQL Database Table Prefix", + default: "wp_" }, { - type: 'input', - name: 'server.host', - message: 'Enter the url host', - default: 'localhost' + type: "input", + name: "server.host", + message: "Enter the url host", + default: "localhost" }, { - type: 'input', - name: 'server.port', - message: 'Enter the the port number', - default: '8080' + type: "input", + name: "server.port", + message: "Enter the the port number", + default: "8080" }, { - type: 'confirm', - name: 'install.confirm', - message: 'Run Install script?', + type: "confirm", + name: "install.confirm", + message: "Run Install script?", default: true } ]; diff --git a/lib/promptSchema/index.js b/lib/promptSchema/index.js index eb281ab..cde1f37 100644 --- a/lib/promptSchema/index.js +++ b/lib/promptSchema/index.js @@ -1,6 +1,6 @@ -const config = require('./config'); -const installConfig = require('./installConfig'); -const theme = require('./theme'); +const config = require("./config"); +const installConfig = require("./installConfig"); +const theme = require("./theme"); module.exports = { config, diff --git a/lib/promptSchema/installConfig.js b/lib/promptSchema/installConfig.js index 0c56f7c..6f2fc80 100644 --- a/lib/promptSchema/installConfig.js +++ b/lib/promptSchema/installConfig.js @@ -1,25 +1,25 @@ module.exports = [ { - type: 'input', - name: 'install.user', - message: 'Enter the admin user name', - default: 'admin' + type: "input", + name: "install.user", + message: "Enter the admin user name", + default: "admin" }, { - type: 'input', - name: 'install.userEmail', - message: 'Enter the admin email', + type: "input", + name: "install.userEmail", + message: "Enter the admin email", validate(email) { - if (!email || (email.trim() === '') || (email.indexOf('@') === -1)) { - return 'Please enter a valid e-mail address!'; + if (!email || email.trim() === "" || email.indexOf("@") === -1) { + return "Please enter a valid e-mail address!"; } return true; } }, { - type: 'password', - name: 'install.userPwd', - message: 'Enter the admin user password', - default: 'admin' + type: "password", + name: "install.userPwd", + message: "Enter the admin user password", + default: "admin" } ]; diff --git a/lib/promptSchema/theme.js b/lib/promptSchema/theme.js index e009bad..96358a0 100644 --- a/lib/promptSchema/theme.js +++ b/lib/promptSchema/theme.js @@ -1,43 +1,43 @@ module.exports = [ { - type: 'input', - name: 'themeName', - message: 'Enter the theme name', + type: "input", + name: "themeName", + message: "Enter the theme name", validate(value) { - if (!value || value.trim() === '') { - return 'Please provide a theme name here!'; + if (!value || value.trim() === "") { + return "Please provide a theme name here!"; } return true; } }, { - type: 'input', - name: 'themeUri', - message: 'Enter the theme URI', - default: '' + type: "input", + name: "themeUri", + message: "Enter the theme URI", + default: "" }, { - type: 'input', - name: 'author', - message: 'Enter author name', - default: '' + type: "input", + name: "author", + message: "Enter author name", + default: "" }, { - type: 'input', - name: 'authorUri', - message: 'Enter author URI', - default: '' + type: "input", + name: "authorUri", + message: "Enter author URI", + default: "" }, { - type: 'input', - name: 'description', - message: 'Enter the Description', - default: '' + type: "input", + name: "description", + message: "Enter the Description", + default: "" }, { - type: 'input', - name: 'version', - message: 'Enter the version', - default: '1.0.0' + type: "input", + name: "version", + message: "Enter the version", + default: "1.0.0" } ]; diff --git a/lib/updateNotifier.js b/lib/updateNotifier.js index 7cb6f1a..4651553 100644 --- a/lib/updateNotifier.js +++ b/lib/updateNotifier.js @@ -1,4 +1,4 @@ -const updateNotifier = require('update-notifier'); -const pkg = require('../package.json'); +const updateNotifier = require("update-notifier"); +const pkg = require("../package.json"); updateNotifier({ pkg }).notify(); diff --git a/package.json b/package.json index 74edfea..23babf1 100644 --- a/package.json +++ b/package.json @@ -7,7 +7,9 @@ }, "scripts": { "lint": "eslint ./bin ./lib", - "test": "npm run lint" + "prettier": "prettier --write ./lib/**/*.js ./lib/**/*.css ./lib/**/*.json ./bin/**/*.js", + "test": "npm run lint", + "precommit": "npm run lint && npm run prettier" }, "author": "thinkholic (http://www.thinkholic.com)", "license": "MIT", @@ -35,8 +37,13 @@ "babel-eslint": "^7.1.1", "eslint": "^3.16.1", "eslint-config-airbnb": "^14.1.0", + "eslint-config-prettier": "^2.6.0", "eslint-plugin-import": "^2.2.0", "eslint-plugin-jsx-a11y": "^4.0.0", - "eslint-plugin-react": "^6.10.0" + "eslint-plugin-prettier": "^2.3.1", + "eslint-plugin-react": "^6.10.0", + "husky": "^0.14.3", + "lint-staged": "^4.3.0", + "prettier": "^1.7.4" } } diff --git a/yarn.lock b/yarn.lock index 5b5b673..e824381 100644 --- a/yarn.lock +++ b/yarn.lock @@ -33,7 +33,7 @@ ansi-align@^1.1.0: dependencies: string-width "^1.0.1" -ansi-escapes@^1.1.0: +ansi-escapes@^1.0.0, ansi-escapes@^1.1.0: version "1.4.0" resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-1.4.0.tgz#d3a8a83b319aa67793662b13e761c7911422306e" @@ -41,10 +41,24 @@ ansi-regex@^2.0.0: version "2.1.1" resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-2.1.1.tgz#c3b33ab5ee360d86e0e628f0468ae7ef27d654df" +ansi-regex@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-3.0.0.tgz#ed0317c322064f79466c02966bddb605ab37d998" + ansi-styles@^2.2.1: version "2.2.1" resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-2.2.1.tgz#b432dd3358b634cf75e1e4664368240533c1ddbe" +ansi-styles@^3.1.0, ansi-styles@^3.2.0: + version "3.2.0" + resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-3.2.0.tgz#c159b8d5be0f9e5a6f346dab94f16ce022161b88" + dependencies: + color-convert "^1.9.0" + +app-root-path@^2.0.0: + version "2.0.1" + resolved "https://registry.yarnpkg.com/app-root-path/-/app-root-path-2.0.1.tgz#cd62dcf8e4fd5a417efc664d2e5b10653c651b46" + argparse@^1.0.7: version "1.0.9" resolved "https://registry.yarnpkg.com/argparse/-/argparse-1.0.9.tgz#73d83bc263f86e97f8cc4f6bae1b0e90a7d22c86" @@ -144,6 +158,10 @@ balanced-match@^0.4.1: version "0.4.2" resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-0.4.2.tgz#cb3f3e3c732dc0f01ee70b403f302e61d7709838" +balanced-match@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-1.0.0.tgz#89b4d199ab2bee49de164ea02b89ce462d71b767" + bignumber.js@3.1.2: version "3.1.2" resolved "https://registry.yarnpkg.com/bignumber.js/-/bignumber.js-3.1.2.tgz#f3bdb99ad5268a15fc1f0bed2fb018e2693fe236" @@ -167,6 +185,13 @@ brace-expansion@^1.0.0: balanced-match "^0.4.1" concat-map "0.0.1" +brace-expansion@^1.1.7: + version "1.1.8" + resolved "https://registry.yarnpkg.com/brace-expansion/-/brace-expansion-1.1.8.tgz#c07b211c7c952ec1f8efd51a77ef0d1d3990a292" + dependencies: + balanced-match "^1.0.0" + concat-map "0.0.1" + buffer-shims@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/buffer-shims/-/buffer-shims-1.0.0.tgz#9978ce317388c649ad8793028c3477ef044a8b51" @@ -203,6 +228,18 @@ chalk@^1.0.0, chalk@^1.1.0, chalk@^1.1.1, chalk@^1.1.3: strip-ansi "^3.0.0" supports-color "^2.0.0" +chalk@^2.0.1, chalk@^2.1.0: + version "2.3.0" + resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.3.0.tgz#b5ea48efc9c1793dccc9b4767c93914d3f2d52ba" + dependencies: + ansi-styles "^3.1.0" + escape-string-regexp "^1.0.5" + supports-color "^4.0.0" + +ci-info@^1.0.0: + version "1.1.1" + resolved "https://registry.yarnpkg.com/ci-info/-/ci-info-1.1.1.tgz#47b44df118c48d2597b56d342e7e25791060171a" + circular-json@^0.3.1: version "0.3.1" resolved "https://registry.yarnpkg.com/circular-json/-/circular-json-0.3.1.tgz#be8b36aefccde8b3ca7aa2d6afc07a37242c0d2d" @@ -211,7 +248,7 @@ cli-boxes@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/cli-boxes/-/cli-boxes-1.0.0.tgz#4fa917c3e59c94a004cd61f8ee509da651687143" -cli-cursor@^1.0.1: +cli-cursor@^1.0.1, cli-cursor@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/cli-cursor/-/cli-cursor-1.0.2.tgz#64da3f7d56a54412e59794bd62dc35295e8f2987" dependencies: @@ -223,6 +260,17 @@ cli-cursor@^2.1.0: dependencies: restore-cursor "^2.0.0" +cli-spinners@^0.1.2: + version "0.1.2" + resolved "https://registry.yarnpkg.com/cli-spinners/-/cli-spinners-0.1.2.tgz#bb764d88e185fb9e1e6a2a1f19772318f605e31c" + +cli-truncate@^0.2.1: + version "0.2.1" + resolved "https://registry.yarnpkg.com/cli-truncate/-/cli-truncate-0.2.1.tgz#9f15cfbb0705005369216c626ac7d05ab90dd574" + dependencies: + slice-ansi "0.0.4" + string-width "^1.0.1" + cli-width@^2.0.0: version "2.1.0" resolved "https://registry.yarnpkg.com/cli-width/-/cli-width-2.1.0.tgz#b234ca209b29ef66fc518d9b98d5847b00edf00a" @@ -235,6 +283,20 @@ code-point-at@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/code-point-at/-/code-point-at-1.1.0.tgz#0d070b4d043a5bea33a2f1a40e2edb3d9a4ccf77" +color-convert@^1.9.0: + version "1.9.0" + resolved "https://registry.yarnpkg.com/color-convert/-/color-convert-1.9.0.tgz#1accf97dd739b983bf994d56fec8f95853641b7a" + dependencies: + color-name "^1.1.1" + +color-name@^1.1.1: + version "1.1.3" + resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.3.tgz#a7d0558bd89c42f795dd42328f740831ca53bc25" + +commander@^2.11.0: + version "2.11.0" + resolved "https://registry.yarnpkg.com/commander/-/commander-2.11.0.tgz#157152fd1e7a6c8d98a5b715cf376df928004563" + commander@^2.9.0: version "2.9.0" resolved "https://registry.yarnpkg.com/commander/-/commander-2.9.0.tgz#9c99094176e12240cb22d6c5146098400fe0f7d4" @@ -276,6 +338,19 @@ core-util-is@~1.0.0: version "1.0.2" resolved "https://registry.yarnpkg.com/core-util-is/-/core-util-is-1.0.2.tgz#b5fd54220aa2bc5ab57aab7140c940754503c1a7" +cosmiconfig@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/cosmiconfig/-/cosmiconfig-1.1.0.tgz#0dea0f9804efdfb929fbb1b188e25553ea053d37" + dependencies: + graceful-fs "^4.1.2" + js-yaml "^3.4.3" + minimist "^1.2.0" + object-assign "^4.0.1" + os-homedir "^1.0.1" + parse-json "^2.2.0" + pinkie-promise "^2.0.0" + require-from-string "^1.1.0" + create-error-class@^3.0.0: version "3.0.2" resolved "https://registry.yarnpkg.com/create-error-class/-/create-error-class-3.0.2.tgz#06be7abef947a3f14a30fd610671d401bca8b7b6" @@ -289,6 +364,14 @@ cross-spawn-async@^2.1.1: lru-cache "^4.0.0" which "^1.2.8" +cross-spawn@^5.0.1: + version "5.1.0" + resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-5.1.0.tgz#e8bd0efee58fcff6f8f94510a0a554bbfa235449" + dependencies: + lru-cache "^4.0.1" + shebang-command "^1.2.0" + which "^1.2.9" + crypto-random-string@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/crypto-random-string/-/crypto-random-string-1.0.0.tgz#a230f64f568310e1498009940790ec99545bca7e" @@ -303,6 +386,10 @@ damerau-levenshtein@^1.0.0: version "1.0.3" resolved "https://registry.yarnpkg.com/damerau-levenshtein/-/damerau-levenshtein-1.0.3.tgz#ae4f4ce0b62acae10ff63a01bb08f652f5213af2" +date-fns@^1.27.2: + version "1.29.0" + resolved "https://registry.yarnpkg.com/date-fns/-/date-fns-1.29.0.tgz#12e609cdcb935127311d04d33334e2960a2a54e6" + debug@2.2.0: version "2.2.0" resolved "https://registry.yarnpkg.com/debug/-/debug-2.2.0.tgz#f87057e995b1a1f6ae6a4960664137bc56f039da" @@ -359,10 +446,20 @@ duplexer3@^0.1.4: version "0.1.4" resolved "https://registry.yarnpkg.com/duplexer3/-/duplexer3-0.1.4.tgz#ee01dd1cac0ed3cbc7fdbea37dc0a8f1ce002ce2" +elegant-spinner@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/elegant-spinner/-/elegant-spinner-1.0.1.tgz#db043521c95d7e303fd8f345bedc3349cfb0729e" + emoji-regex@^6.1.0: version "6.1.0" resolved "https://registry.yarnpkg.com/emoji-regex/-/emoji-regex-6.1.0.tgz#d14ef743a7dfa6eaf436882bd1920a4aed84dd94" +error-ex@^1.2.0: + version "1.3.1" + resolved "https://registry.yarnpkg.com/error-ex/-/error-ex-1.3.1.tgz#f855a86ce61adc4e8621c3cda21e7a7612c3a8dc" + dependencies: + is-arrayish "^0.2.1" + es-abstract@^1.7.0: version "1.7.0" resolved "https://registry.yarnpkg.com/es-abstract/-/es-abstract-1.7.0.tgz#dfade774e01bfcd97f96180298c449c8623fb94c" @@ -455,6 +552,12 @@ eslint-config-airbnb@^14.1.0: dependencies: eslint-config-airbnb-base "^11.1.0" +eslint-config-prettier@^2.6.0: + version "2.6.0" + resolved "https://registry.yarnpkg.com/eslint-config-prettier/-/eslint-config-prettier-2.6.0.tgz#f21db0ebb438ad678fb98946097c4bb198befccc" + dependencies: + get-stdin "^5.0.1" + eslint-import-resolver-node@^0.2.0: version "0.2.3" resolved "https://registry.yarnpkg.com/eslint-import-resolver-node/-/eslint-import-resolver-node-0.2.3.tgz#5add8106e8c928db2cba232bcd9efa846e3da16c" @@ -496,6 +599,13 @@ eslint-plugin-jsx-a11y@^4.0.0: jsx-ast-utils "^1.0.0" object-assign "^4.0.1" +eslint-plugin-prettier@^2.3.1: + version "2.3.1" + resolved "https://registry.yarnpkg.com/eslint-plugin-prettier/-/eslint-plugin-prettier-2.3.1.tgz#e7a746c67e716f335274b88295a9ead9f544e44d" + dependencies: + fast-diff "^1.1.1" + jest-docblock "^21.0.0" + eslint-plugin-react@^6.10.0: version "6.10.0" resolved "https://registry.yarnpkg.com/eslint-plugin-react/-/eslint-plugin-react-6.10.0.tgz#9c48b48d101554b5355413e7c64238abde6ef1ef" @@ -556,6 +666,10 @@ esprima@^3.1.1: version "3.1.3" resolved "https://registry.yarnpkg.com/esprima/-/esprima-3.1.3.tgz#fdca51cee6133895e3c88d535ce49dbff62a4633" +esprima@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/esprima/-/esprima-4.0.0.tgz#4499eddcd1110e0b218bacf2fa7f7f59f55ca804" + esrecurse@^4.1.0: version "4.1.0" resolved "https://registry.yarnpkg.com/esrecurse/-/esrecurse-4.1.0.tgz#4713b6536adf7f2ac4f327d559e7756bff648220" @@ -593,6 +707,18 @@ execa@^0.4.0: path-key "^1.0.0" strip-eof "^1.0.0" +execa@^0.8.0: + version "0.8.0" + resolved "https://registry.yarnpkg.com/execa/-/execa-0.8.0.tgz#d8d76bbc1b55217ed190fd6dd49d3c774ecfc8da" + dependencies: + cross-spawn "^5.0.1" + get-stream "^3.0.0" + is-stream "^1.1.0" + npm-run-path "^2.0.0" + p-finally "^1.0.0" + signal-exit "^3.0.0" + strip-eof "^1.0.0" + exit-hook@^1.0.0: version "1.1.1" resolved "https://registry.yarnpkg.com/exit-hook/-/exit-hook-1.1.1.tgz#f05ca233b48c05d54fff07765df8507e95c02ff8" @@ -603,11 +729,15 @@ external-editor@^2.0.1: dependencies: tmp "^0.0.31" +fast-diff@^1.1.1: + version "1.1.2" + resolved "https://registry.yarnpkg.com/fast-diff/-/fast-diff-1.1.2.tgz#4b62c42b8e03de3f848460b639079920695d0154" + fast-levenshtein@~2.0.4: version "2.0.6" resolved "https://registry.yarnpkg.com/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz#3d8a5c66883a16a30ca8643e851f19baa7797917" -figures@^1.3.5: +figures@^1.3.5, figures@^1.7.0: version "1.7.0" resolved "https://registry.yarnpkg.com/figures/-/figures-1.7.0.tgz#cbe1e3affcf1cd44b80cadfed28dc793a9701d2e" dependencies: @@ -676,6 +806,14 @@ generate-object-property@^1.1.0: dependencies: is-property "^1.0.0" +get-own-enumerable-property-symbols@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/get-own-enumerable-property-symbols/-/get-own-enumerable-property-symbols-2.0.1.tgz#5c4ad87f2834c4b9b4e84549dc1e0650fb38c24b" + +get-stdin@^5.0.1: + version "5.0.1" + resolved "https://registry.yarnpkg.com/get-stdin/-/get-stdin-5.0.1.tgz#122e161591e21ff4c52530305693f20e6393a398" + get-stream@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/get-stream/-/get-stream-3.0.0.tgz#8e943d1358dc37555054ecbe2edb05aa174ede14" @@ -736,12 +874,24 @@ has-ansi@^2.0.0: dependencies: ansi-regex "^2.0.0" +has-flag@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-2.0.0.tgz#e8207af1cc7b30d446cc70b734b5e8be18f88d51" + has@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/has/-/has-1.0.1.tgz#8461733f538b0837c9361e39a9ab9e9704dc2f28" dependencies: function-bind "^1.0.2" +husky@^0.14.3: + version "0.14.3" + resolved "https://registry.yarnpkg.com/husky/-/husky-0.14.3.tgz#c69ed74e2d2779769a17ba8399b54ce0b63c12c3" + dependencies: + is-ci "^1.0.10" + normalize-path "^1.0.0" + strip-indent "^2.0.0" + ignore@^3.2.0: version "3.2.4" resolved "https://registry.yarnpkg.com/ignore/-/ignore-3.2.4.tgz#4055e03596729a8fabe45a43c100ad5ed815c4e8" @@ -750,6 +900,16 @@ imurmurhash@^0.1.4: version "0.1.4" resolved "https://registry.yarnpkg.com/imurmurhash/-/imurmurhash-0.1.4.tgz#9218b9b2b928a238b13dc4fb6b6d576f231453ea" +indent-string@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/indent-string/-/indent-string-2.1.0.tgz#8e2d48348742121b4a8218b7a137e9a52049dc80" + dependencies: + repeating "^2.0.0" + +indent-string@^3.0.0: + version "3.2.0" + resolved "https://registry.yarnpkg.com/indent-string/-/indent-string-3.2.0.tgz#4a5fd6d27cc332f37e5419a504dbb837105c9289" + inflight@^1.0.4: version "1.0.6" resolved "https://registry.yarnpkg.com/inflight/-/inflight-1.0.6.tgz#49bd6331d7d02d0c09bc910a1075ba8165b56df9" @@ -811,14 +971,34 @@ invariant@^2.2.0: dependencies: loose-envify "^1.0.0" +is-arrayish@^0.2.1: + version "0.2.1" + resolved "https://registry.yarnpkg.com/is-arrayish/-/is-arrayish-0.2.1.tgz#77c99840527aa8ecb1a8ba697b80645a7a926a9d" + is-callable@^1.1.1, is-callable@^1.1.3: version "1.1.3" resolved "https://registry.yarnpkg.com/is-callable/-/is-callable-1.1.3.tgz#86eb75392805ddc33af71c92a0eedf74ee7604b2" +is-ci@^1.0.10: + version "1.0.10" + resolved "https://registry.yarnpkg.com/is-ci/-/is-ci-1.0.10.tgz#f739336b2632365061a9d48270cd56ae3369318e" + dependencies: + ci-info "^1.0.0" + is-date-object@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/is-date-object/-/is-date-object-1.0.1.tgz#9aa20eb6aeebbff77fbd33e74ca01b33581d3a16" +is-extglob@^2.1.1: + version "2.1.1" + resolved "https://registry.yarnpkg.com/is-extglob/-/is-extglob-2.1.1.tgz#a88c02535791f02ed37c76a1b9ea9773c833f8c2" + +is-finite@^1.0.0: + version "1.0.2" + resolved "https://registry.yarnpkg.com/is-finite/-/is-finite-1.0.2.tgz#cc6677695602be550ef11e8b4aa6305342b6d0aa" + dependencies: + number-is-nan "^1.0.0" + is-fullwidth-code-point@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz#ef9e31386f031a7f0d643af82fde50c457ef00cb" @@ -829,6 +1009,12 @@ is-fullwidth-code-point@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz#a3b30a5c4f199183167aaab93beefae3ddfb654f" +is-glob@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/is-glob/-/is-glob-4.0.0.tgz#9521c76845cc2610a85203ddf080a958c2ffabc0" + dependencies: + is-extglob "^2.1.1" + is-my-json-valid@^2.10.0: version "2.16.0" resolved "https://registry.yarnpkg.com/is-my-json-valid/-/is-my-json-valid-2.16.0.tgz#f079dd9bfdae65ee2038aae8acbc86ab109e3693" @@ -842,7 +1028,7 @@ is-npm@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-npm/-/is-npm-1.0.0.tgz#f2fb63a65e4905b406c86072765a1a4dc793b9f4" -is-obj@^1.0.0: +is-obj@^1.0.0, is-obj@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/is-obj/-/is-obj-1.0.1.tgz#3e4729ac1f5fde025cd7d83a896dab9f4f67db0f" @@ -880,6 +1066,10 @@ is-regex@^1.0.3: dependencies: has "^1.0.1" +is-regexp@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/is-regexp/-/is-regexp-1.0.0.tgz#fd2d883545c46bac5a633e7b9a09e87fa2cb5069" + is-resolvable@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-resolvable/-/is-resolvable-1.0.0.tgz#8df57c61ea2e3c501408d100fb013cf8d6e0cc62" @@ -910,10 +1100,38 @@ isexe@^1.1.1: version "1.1.2" resolved "https://registry.yarnpkg.com/isexe/-/isexe-1.1.2.tgz#36f3e22e60750920f5e7241a476a8c6a42275ad0" +isexe@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/isexe/-/isexe-2.0.0.tgz#e8fbf374dc556ff8947a10dcb0572d633f2cfa10" + +jest-docblock@^21.0.0: + version "21.2.0" + resolved "https://registry.yarnpkg.com/jest-docblock/-/jest-docblock-21.2.0.tgz#51529c3b30d5fd159da60c27ceedc195faf8d414" + +jest-get-type@^21.2.0: + version "21.2.0" + resolved "https://registry.yarnpkg.com/jest-get-type/-/jest-get-type-21.2.0.tgz#f6376ab9db4b60d81e39f30749c6c466f40d4a23" + +jest-validate@^21.1.0: + version "21.2.1" + resolved "https://registry.yarnpkg.com/jest-validate/-/jest-validate-21.2.1.tgz#cc0cbca653cd54937ba4f2a111796774530dd3c7" + dependencies: + chalk "^2.0.1" + jest-get-type "^21.2.0" + leven "^2.1.0" + pretty-format "^21.2.1" + js-tokens@^3.0.0: version "3.0.1" resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-3.0.1.tgz#08e9f132484a2c45a30907e9dc4d5567b7f114d7" +js-yaml@^3.4.3: + version "3.10.0" + resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.10.0.tgz#2e78441646bd4682e963f22b6e92823c309c62dc" + dependencies: + argparse "^1.0.7" + esprima "^4.0.0" + js-yaml@^3.5.1: version "3.8.1" resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.8.1.tgz#782ba50200be7b9e5a8537001b7804db3ad02628" @@ -957,6 +1175,10 @@ lazy-req@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/lazy-req/-/lazy-req-2.0.0.tgz#c9450a363ecdda2e6f0c70132ad4f37f8f06f2b4" +leven@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/leven/-/leven-2.1.0.tgz#c2e7a9f772094dee9d34202ae8acce4687875580" + levn@^0.3.0, levn@~0.3.0: version "0.3.0" resolved "https://registry.yarnpkg.com/levn/-/levn-0.3.0.tgz#3b09924edf9f083c0490fdd4c0bc4421e04764ee" @@ -964,6 +1186,73 @@ levn@^0.3.0, levn@~0.3.0: prelude-ls "~1.1.2" type-check "~0.3.2" +lint-staged@^4.3.0: + version "4.3.0" + resolved "https://registry.yarnpkg.com/lint-staged/-/lint-staged-4.3.0.tgz#ed0779ad9a42c0dc62bb3244e522870b41125879" + dependencies: + app-root-path "^2.0.0" + chalk "^2.1.0" + commander "^2.11.0" + cosmiconfig "^1.1.0" + execa "^0.8.0" + is-glob "^4.0.0" + jest-validate "^21.1.0" + listr "^0.12.0" + lodash "^4.17.4" + log-symbols "^2.0.0" + minimatch "^3.0.0" + npm-which "^3.0.1" + p-map "^1.1.1" + staged-git-files "0.0.4" + stringify-object "^3.2.0" + +listr-silent-renderer@^1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/listr-silent-renderer/-/listr-silent-renderer-1.1.1.tgz#924b5a3757153770bf1a8e3fbf74b8bbf3f9242e" + +listr-update-renderer@^0.2.0: + version "0.2.0" + resolved "https://registry.yarnpkg.com/listr-update-renderer/-/listr-update-renderer-0.2.0.tgz#ca80e1779b4e70266807e8eed1ad6abe398550f9" + dependencies: + chalk "^1.1.3" + cli-truncate "^0.2.1" + elegant-spinner "^1.0.1" + figures "^1.7.0" + indent-string "^3.0.0" + log-symbols "^1.0.2" + log-update "^1.0.2" + strip-ansi "^3.0.1" + +listr-verbose-renderer@^0.4.0: + version "0.4.1" + resolved "https://registry.yarnpkg.com/listr-verbose-renderer/-/listr-verbose-renderer-0.4.1.tgz#8206f4cf6d52ddc5827e5fd14989e0e965933a35" + dependencies: + chalk "^1.1.3" + cli-cursor "^1.0.2" + date-fns "^1.27.2" + figures "^1.7.0" + +listr@^0.12.0: + version "0.12.0" + resolved "https://registry.yarnpkg.com/listr/-/listr-0.12.0.tgz#6bce2c0f5603fa49580ea17cd6a00cc0e5fa451a" + dependencies: + chalk "^1.1.3" + cli-truncate "^0.2.1" + figures "^1.7.0" + indent-string "^2.1.0" + is-promise "^2.1.0" + is-stream "^1.1.0" + listr-silent-renderer "^1.1.1" + listr-update-renderer "^0.2.0" + listr-verbose-renderer "^0.4.0" + log-symbols "^1.0.2" + log-update "^1.0.2" + ora "^0.2.3" + p-map "^1.1.1" + rxjs "^5.0.0-beta.11" + stream-to-observable "^0.1.0" + strip-ansi "^3.0.1" + lodash.cond@^4.3.0: version "4.5.2" resolved "https://registry.yarnpkg.com/lodash.cond/-/lodash.cond-4.5.2.tgz#f471a1da486be60f6ab955d17115523dd1d255d5" @@ -976,6 +1265,25 @@ lodash@^4.0.0, lodash@^4.17.4, lodash@^4.2.0, lodash@^4.3.0: version "4.17.4" resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.4.tgz#78203a4d1c328ae1d86dca6460e369b57f4055ae" +log-symbols@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/log-symbols/-/log-symbols-1.0.2.tgz#376ff7b58ea3086a0f09facc74617eca501e1a18" + dependencies: + chalk "^1.0.0" + +log-symbols@^2.0.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/log-symbols/-/log-symbols-2.1.0.tgz#f35fa60e278832b538dc4dddcbb478a45d3e3be6" + dependencies: + chalk "^2.0.1" + +log-update@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/log-update/-/log-update-1.0.2.tgz#19929f64c4093d2d2e7075a1dad8af59c296b8d1" + dependencies: + ansi-escapes "^1.0.0" + cli-cursor "^1.0.2" + loose-envify@^1.0.0: version "1.3.1" resolved "https://registry.yarnpkg.com/loose-envify/-/loose-envify-1.3.1.tgz#d1a8ad33fa9ce0e713d65fdd0ac8b748d478c848" @@ -993,10 +1301,23 @@ lru-cache@^4.0.0: pseudomap "^1.0.1" yallist "^2.0.0" +lru-cache@^4.0.1: + version "4.1.1" + resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-4.1.1.tgz#622e32e82488b49279114a4f9ecf45e7cd6bba55" + dependencies: + pseudomap "^1.0.2" + yallist "^2.1.2" + mimic-fn@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-1.1.0.tgz#e667783d92e89dbd342818b5230b9d62a672ad18" +minimatch@^3.0.0: + version "3.0.4" + resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.0.4.tgz#5166e286457f03306064be5497e8dbb0c3d32083" + dependencies: + brace-expansion "^1.1.7" + minimatch@^3.0.2, minimatch@^3.0.3: version "3.0.3" resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.0.3.tgz#2a4e4090b96b2db06a9d7df01055a62a77c9b774" @@ -1052,12 +1373,36 @@ node-wp-cli@0.0.2: lodash "^4.17.4" shelljs "^0.7.6" +normalize-path@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/normalize-path/-/normalize-path-1.0.0.tgz#32d0e472f91ff345701c15a8311018d3b0a90379" + +npm-path@^2.0.2: + version "2.0.3" + resolved "https://registry.yarnpkg.com/npm-path/-/npm-path-2.0.3.tgz#15cff4e1c89a38da77f56f6055b24f975dfb2bbe" + dependencies: + which "^1.2.10" + npm-run-path@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/npm-run-path/-/npm-run-path-1.0.0.tgz#f5c32bf595fe81ae927daec52e82f8b000ac3c8f" dependencies: path-key "^1.0.0" +npm-run-path@^2.0.0: + version "2.0.2" + resolved "https://registry.yarnpkg.com/npm-run-path/-/npm-run-path-2.0.2.tgz#35a9232dfa35d7067b4cb2ddf2357b1871536c5f" + dependencies: + path-key "^2.0.0" + +npm-which@^3.0.1: + version "3.0.1" + resolved "https://registry.yarnpkg.com/npm-which/-/npm-which-3.0.1.tgz#9225f26ec3a285c209cae67c3b11a6b4ab7140aa" + dependencies: + commander "^2.9.0" + npm-path "^2.0.2" + which "^1.2.10" + number-is-nan@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/number-is-nan/-/number-is-nan-1.0.1.tgz#097b602b53422a522c1afb8790318336941a011d" @@ -1105,7 +1450,16 @@ optionator@^0.8.2: type-check "~0.3.2" wordwrap "~1.0.0" -os-homedir@^1.0.0: +ora@^0.2.3: + version "0.2.3" + resolved "https://registry.yarnpkg.com/ora/-/ora-0.2.3.tgz#37527d220adcd53c39b73571d754156d5db657a4" + dependencies: + chalk "^1.1.1" + cli-cursor "^1.0.2" + cli-spinners "^0.1.2" + object-assign "^4.0.1" + +os-homedir@^1.0.0, os-homedir@^1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/os-homedir/-/os-homedir-1.0.2.tgz#ffbc4988336e0e833de0c168c7ef152121aa7fb3" @@ -1113,6 +1467,14 @@ os-tmpdir@~1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/os-tmpdir/-/os-tmpdir-1.0.2.tgz#bbe67406c79aa85c5cfec766fe5734555dfa1274" +p-finally@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/p-finally/-/p-finally-1.0.0.tgz#3fbcfb15b899a44123b34b6dcc18b724336a2cae" + +p-map@^1.1.1: + version "1.2.0" + resolved "https://registry.yarnpkg.com/p-map/-/p-map-1.2.0.tgz#e4e94f311eabbc8633a1e79908165fca26241b6b" + package-json@^3.0.0: version "3.1.0" resolved "https://registry.yarnpkg.com/package-json/-/package-json-3.1.0.tgz#ce281900fe8052150cc6709c6c006c18fdb2f379" @@ -1122,6 +1484,12 @@ package-json@^3.0.0: registry-url "^3.0.3" semver "^5.1.0" +parse-json@^2.2.0: + version "2.2.0" + resolved "https://registry.yarnpkg.com/parse-json/-/parse-json-2.2.0.tgz#f480f40434ef80741f8469099f8dea18f55a4dc9" + dependencies: + error-ex "^1.2.0" + path-exists@^2.0.0: version "2.1.0" resolved "https://registry.yarnpkg.com/path-exists/-/path-exists-2.1.0.tgz#0feb6c64f0fc518d9a754dd5efb62c7022761f4b" @@ -1140,6 +1508,10 @@ path-key@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/path-key/-/path-key-1.0.0.tgz#5d53d578019646c0d68800db4e146e6bdc2ac7af" +path-key@^2.0.0: + version "2.0.1" + resolved "https://registry.yarnpkg.com/path-key/-/path-key-2.0.1.tgz#411cadb574c5a140d3a4b1910d40d80cc9f40b40" + path-parse@^1.0.5: version "1.0.5" resolved "https://registry.yarnpkg.com/path-parse/-/path-parse-1.0.5.tgz#3c1adf871ea9cd6c9431b6ea2bd74a0ff055c4c1" @@ -1182,6 +1554,17 @@ prepend-http@^1.0.1: version "1.0.4" resolved "https://registry.yarnpkg.com/prepend-http/-/prepend-http-1.0.4.tgz#d4f4562b0ce3696e41ac52d0e002e57a635dc6dc" +prettier@^1.7.4: + version "1.7.4" + resolved "https://registry.yarnpkg.com/prettier/-/prettier-1.7.4.tgz#5e8624ae9363c80f95ec644584ecdf55d74f93fa" + +pretty-format@^21.2.1: + version "21.2.1" + resolved "https://registry.yarnpkg.com/pretty-format/-/pretty-format-21.2.1.tgz#ae5407f3cf21066cd011aa1ba5fce7b6a2eddb36" + dependencies: + ansi-regex "^3.0.0" + ansi-styles "^3.2.0" + process-nextick-args@~1.0.6: version "1.0.7" resolved "https://registry.yarnpkg.com/process-nextick-args/-/process-nextick-args-1.0.7.tgz#150e20b756590ad3f91093f25a4f2ad8bff30ba3" @@ -1190,7 +1573,7 @@ progress@^1.1.8: version "1.1.8" resolved "https://registry.yarnpkg.com/progress/-/progress-1.1.8.tgz#e260c78f6161cdd9b0e56cc3e0a85de17c7a57be" -pseudomap@^1.0.1: +pseudomap@^1.0.1, pseudomap@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/pseudomap/-/pseudomap-1.0.2.tgz#f052a28da70e618917ef0a8ac34c1ae5a68286b3" @@ -1254,6 +1637,16 @@ registry-url@^3.0.3: dependencies: rc "^1.0.1" +repeating@^2.0.0: + version "2.0.1" + resolved "https://registry.yarnpkg.com/repeating/-/repeating-2.0.1.tgz#5214c53a926d3552707527fbab415dbc08d06dda" + dependencies: + is-finite "^1.0.0" + +require-from-string@^1.1.0: + version "1.2.1" + resolved "https://registry.yarnpkg.com/require-from-string/-/require-from-string-1.2.1.tgz#529c9ccef27380adfec9a2f965b649bbee636418" + require-uncached@^1.0.2: version "1.0.3" resolved "https://registry.yarnpkg.com/require-uncached/-/require-uncached-1.0.3.tgz#4e0d56d6c9662fd31e43011c4b95aa49955421d3" @@ -1311,6 +1704,12 @@ rx@^4.1.0: version "4.1.0" resolved "https://registry.yarnpkg.com/rx/-/rx-4.1.0.tgz#a5f13ff79ef3b740fe30aa803fb09f98805d4782" +rxjs@^5.0.0-beta.11: + version "5.5.2" + resolved "https://registry.yarnpkg.com/rxjs/-/rxjs-5.5.2.tgz#28d403f0071121967f18ad665563255d54236ac3" + dependencies: + symbol-observable "^1.0.1" + safe-buffer@^5.0.1: version "5.0.1" resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.0.1.tgz#d263ca54696cd8a306b5ca6551e92de57918fbe7" @@ -1325,6 +1724,16 @@ semver@^5.0.3, semver@^5.1.0: version "5.3.0" resolved "https://registry.yarnpkg.com/semver/-/semver-5.3.0.tgz#9b2ce5d3de02d17c6012ad326aa6b4d0cf54f94f" +shebang-command@^1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/shebang-command/-/shebang-command-1.2.0.tgz#44aac65b695b03398968c39f363fee5deafdf1ea" + dependencies: + shebang-regex "^1.0.0" + +shebang-regex@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/shebang-regex/-/shebang-regex-1.0.0.tgz#da42f49740c0b42db2ca9728571cb190c98efea3" + shelljs@^0.7.5, shelljs@^0.7.6: version "0.7.6" resolved "https://registry.yarnpkg.com/shelljs/-/shelljs-0.7.6.tgz#379cccfb56b91c8601e4793356eb5382924de9ad" @@ -1333,7 +1742,7 @@ shelljs@^0.7.5, shelljs@^0.7.6: interpret "^1.0.0" rechoir "^0.6.2" -signal-exit@^3.0.2: +signal-exit@^3.0.0, signal-exit@^3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/signal-exit/-/signal-exit-3.0.2.tgz#b5fdc08f1287ea1178628e415e25132b73646c6d" @@ -1353,6 +1762,14 @@ sqlstring@2.2.0: version "2.2.0" resolved "https://registry.yarnpkg.com/sqlstring/-/sqlstring-2.2.0.tgz#c3135c4ea8abcd7e7ee741a4966a891d86a4f191" +staged-git-files@0.0.4: + version "0.0.4" + resolved "https://registry.yarnpkg.com/staged-git-files/-/staged-git-files-0.0.4.tgz#d797e1b551ca7a639dec0237dc6eb4bb9be17d35" + +stream-to-observable@^0.1.0: + version "0.1.0" + resolved "https://registry.yarnpkg.com/stream-to-observable/-/stream-to-observable-0.1.0.tgz#45bf1d9f2d7dc09bed81f1c307c430e68b84cffe" + string-width@^1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/string-width/-/string-width-1.0.2.tgz#118bdf5b8cdc51a2a7e70d211e07e2b0b9b107d3" @@ -1372,7 +1789,15 @@ string_decoder@~0.10.x: version "0.10.31" resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-0.10.31.tgz#62e203bc41766c6c28c9fc84301dab1c5310fa94" -strip-ansi@^3.0.0: +stringify-object@^3.2.0: + version "3.2.1" + resolved "https://registry.yarnpkg.com/stringify-object/-/stringify-object-3.2.1.tgz#2720c2eff940854c819f6ee252aaeb581f30624d" + dependencies: + get-own-enumerable-property-symbols "^2.0.1" + is-obj "^1.0.1" + is-regexp "^1.0.0" + +strip-ansi@^3.0.0, strip-ansi@^3.0.1: version "3.0.1" resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-3.0.1.tgz#6a385fb8853d952d5ff05d0e8aaf94278dc63dcf" dependencies: @@ -1386,6 +1811,10 @@ strip-eof@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/strip-eof/-/strip-eof-1.0.0.tgz#bb43ff5598a6eb05d89b59fcd129c983313606bf" +strip-indent@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/strip-indent/-/strip-indent-2.0.0.tgz#5ef8db295d01e6ed6cbf7aab96998d7822527b68" + strip-json-comments@~2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-2.0.1.tgz#3c531942e908c2697c0ec344858c286c7ca0a60a" @@ -1394,6 +1823,16 @@ supports-color@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-2.0.0.tgz#535d045ce6b6363fa40117084629995e9df324c7" +supports-color@^4.0.0: + version "4.5.0" + resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-4.5.0.tgz#be7a0de484dec5c5cddf8b3d59125044912f635b" + dependencies: + has-flag "^2.0.0" + +symbol-observable@^1.0.1: + version "1.0.4" + resolved "https://registry.yarnpkg.com/symbol-observable/-/symbol-observable-1.0.4.tgz#29bf615d4aa7121bdd898b22d4b3f9bc4e2aa03d" + table@^3.7.8: version "3.8.3" resolved "https://registry.yarnpkg.com/table/-/table-3.8.3.tgz#2bbc542f0fda9861a755d3947fefd8b3f513855f" @@ -1486,6 +1925,12 @@ util-deprecate@~1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/util-deprecate/-/util-deprecate-1.0.2.tgz#450d4dc9fa70de732762fbd2d4a28981419a0ccf" +which@^1.2.10, which@^1.2.9: + version "1.3.0" + resolved "https://registry.yarnpkg.com/which/-/which-1.3.0.tgz#ff04bdfc010ee547d780bec38e1ac1c2777d253a" + dependencies: + isexe "^2.0.0" + which@^1.2.8: version "1.2.12" resolved "https://registry.yarnpkg.com/which/-/which-1.2.12.tgz#de67b5e450269f194909ef23ece4ebe416fa1192" @@ -1531,3 +1976,7 @@ xtend@^4.0.0: yallist@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/yallist/-/yallist-2.0.0.tgz#306c543835f09ee1a4cb23b7bce9ab341c91cdd4" + +yallist@^2.1.2: + version "2.1.2" + resolved "https://registry.yarnpkg.com/yallist/-/yallist-2.1.2.tgz#1c11f9218f076089a47dd512f93c6699a6a81d52"