Comparing version 3.14.0 to 3.15.0
## Change Log | ||
### v3.15.0 (2015/07/06 06:01 +00:00) | ||
- [#197](https://github.com/bcoe/yargs/pull/197) tweaks to how errors bubble up from parser.js (@bcoe) | ||
- [#193](https://github.com/bcoe/yargs/pull/193) upgraded nyc, reporting now happens by default (@bcoe) | ||
### v3.14.0 (2015/06/28 02:12 +00:00) | ||
@@ -4,0 +8,0 @@ |
@@ -479,2 +479,4 @@ var assert = require('assert') | ||
if (parsed.error) throw parsed.error | ||
// if we're executed via bash completion, don't | ||
@@ -481,0 +483,0 @@ // bother with validation. |
@@ -12,2 +12,4 @@ // fancy-pants parsing of argv, originally forked | ||
if (!opts) opts = {} | ||
var error = null | ||
var flags = { arrays: {}, bools: {}, strings: {}, counts: {}, normalize: {}, configs: {} } | ||
@@ -236,3 +238,3 @@ | ||
if (args.length - (i + 1) < toEat) throw Error('not enough arguments following: ' + key) | ||
if (args.length - (i + 1) < toEat) error = Error('not enough arguments following: ' + key) | ||
@@ -336,3 +338,3 @@ for (var ii = i + 1; ii < (toEat + i + 1); ii++) { | ||
} catch (ex) { | ||
throw Error('invalid json config file: ' + configPath) | ||
if (argv[configKey]) error = Error('invalid json config file: ' + configPath) | ||
} | ||
@@ -449,4 +451,5 @@ } | ||
aliases: aliases, | ||
error: error, | ||
newAliases: newAliases | ||
} | ||
} |
{ | ||
"name": "yargs", | ||
"version": "3.14.0", | ||
"version": "3.15.0", | ||
"description": "Light-weight option parsing with an argv hash. No optstrings attached.", | ||
@@ -23,7 +23,7 @@ "main": "./index.js", | ||
"mocha": "^2.2.1", | ||
"nyc": "^2.2.1", | ||
"nyc": "^3.0.0", | ||
"standard": "^4.4.0" | ||
}, | ||
"scripts": { | ||
"test": "standard && nyc mocha --check-leaks && nyc report", | ||
"test": "standard && nyc mocha --check-leaks", | ||
"coverage": "nyc report --reporter=text-lcov | coveralls" | ||
@@ -30,0 +30,0 @@ }, |
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
106166
1328