standard-engine
Advanced tools
Comparing version 5.0.2 to 5.0.3
@@ -5,5 +5,3 @@ #!/usr/bin/env node | ||
var defaults = require('defaults') | ||
var minimist = require('minimist') | ||
var multiline = require('multiline') | ||
var getStdin = require('get-stdin') | ||
@@ -14,7 +12,7 @@ | ||
opts = defaults(opts, { | ||
opts = Object.assign({ | ||
cmd: 'standard-engine', | ||
tagline: 'JavaScript Custom Style', | ||
version: require('../package.json').version | ||
}) | ||
}, opts) | ||
@@ -52,28 +50,25 @@ var argv = minimist(process.argv.slice(2), { | ||
if (opts.tagline) console.log('%s - %s (%s)', opts.cmd, opts.tagline, opts.homepage) | ||
console.log(multiline.stripIndent(function () { | ||
/* | ||
console.log(` | ||
Usage: | ||
${opts.cmd} <flags> [FILES...] | ||
Usage: | ||
%s <flags> [FILES...] | ||
If FILES is omitted, then all JavaScript source files (*.js, *.jsx) in the current | ||
working directory are checked, recursively. | ||
If FILES is omitted, then all JavaScript source files (*.js, *.jsx) in the current | ||
working directory are checked, recursively. | ||
Certain paths (node_modules/, .git/, coverage/, *.min.js, bundle.js, vendor/) are | ||
automatically ignored. | ||
Certain paths (node_modules/, .git/, coverage/, *.min.js, bundle.js, vendor/) are | ||
automatically ignored. | ||
Flags: | ||
--fix Automatically fix problems | ||
-v, --verbose Show rule names for errors (to ignore specific rules) | ||
--version Show current version | ||
-h, --help Show usage information | ||
Flags: | ||
-v, --verbose Show rule names for errors (to ignore specific rules) | ||
--fix Automatically fix problems | ||
--stdin Read file text from stdin | ||
--version Show current version | ||
-h, --help Show usage information | ||
Flags (advanced): | ||
--global Declare global variable | ||
--plugin Use custom eslint plugin | ||
--env Use custom eslint environment | ||
--parser Use custom js parser (e.g. babel-eslint) | ||
*/ | ||
}), opts.cmd) | ||
Flags (advanced): | ||
--stdin Read file text from stdin | ||
--global Declare global variable | ||
--plugin Use custom eslint plugin | ||
--env Use custom eslint environment | ||
--parser Use custom js parser (e.g. babel-eslint) | ||
`) | ||
process.exitCode = 0 | ||
@@ -80,0 +75,0 @@ return |
13
index.js
@@ -5,5 +5,3 @@ module.exports.cli = require('./bin/cmd') | ||
var defaults = require('defaults') | ||
var deglob = require('deglob') | ||
var extend = require('xtend') | ||
var findRoot = require('find-root') | ||
@@ -35,3 +33,3 @@ var pkgConfig = require('pkg-config') | ||
self.eslintConfig = defaults(opts.eslintConfig, { | ||
self.eslintConfig = Object.assign({ | ||
envs: [], | ||
@@ -43,6 +41,3 @@ fix: false, | ||
useEslintrc: false | ||
}) | ||
if (!self.eslintConfig) { | ||
throw new Error('No eslintConfig passed.') | ||
} | ||
}, opts.eslintConfig) | ||
} | ||
@@ -127,4 +122,4 @@ | ||
if (!opts) opts = {} | ||
opts = extend(opts) | ||
opts.eslintConfig = extend(self.eslintConfig) | ||
opts = Object.assign({}, opts) | ||
opts.eslintConfig = Object.assign({}, self.eslintConfig) | ||
@@ -131,0 +126,0 @@ if (!opts.cwd) opts.cwd = self.cwd || process.cwd() |
{ | ||
"name": "standard-engine", | ||
"description": "Wrap your standards in a tortilla and cover it in special sauce.", | ||
"version": "5.0.2", | ||
"version": "5.0.3", | ||
"author": "Dan Flettre <flettre@gmail.com> (http://twitter.com/flettre/)", | ||
@@ -10,10 +10,7 @@ "bugs": { | ||
"dependencies": { | ||
"defaults": "^1.0.2", | ||
"deglob": "^1.0.0", | ||
"deglob": "^2.0.0", | ||
"find-root": "^1.0.0", | ||
"get-stdin": "^5.0.1", | ||
"minimist": "^1.1.0", | ||
"multiline": "^1.0.2", | ||
"pkg-config": "^1.0.1", | ||
"xtend": "^4.0.0" | ||
"pkg-config": "^1.0.1" | ||
}, | ||
@@ -20,0 +17,0 @@ "devDependencies": { |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
5
29482
463
+ Addeddeglob@2.1.1(transitive)
- Removeddefaults@^1.0.2
- Removedmultiline@^1.0.2
- Removedxtend@^4.0.0
- Removedclone@1.0.4(transitive)
- Removeddefaults@1.0.4(transitive)
- Removeddeglob@1.1.2(transitive)
- Removedget-stdin@4.0.1(transitive)
- Removedmultiline@1.0.2(transitive)
- Removedstrip-indent@1.0.1(transitive)
Updateddeglob@^2.0.0