All notable changes to this project will be documented in this file. See standard-version for commit guidelines.
14.0.0 (2019-07-30)
- we now only officially support yargs.$0 parameter and discourage direct access to yargs.parsed
- previously to this fix methods like
yargs.getOptions()
contained the state of the last command to execute. - do not allow additional positionals in strict mode
- calling parse multiple times now appropriately maintains state (#1137) (#1369) (026b151)
- prefer user supplied script name in usage (#1383) (28c74b9)
- deps: use decamelize from npm instead of vendored copy (#1377) (015eeb9)
- examples: fix usage-options.js to reflect current API (#1375) (6e5b76b)
- do not allow additional positionals in strict mode (35d777c)
- properties accessed on singleton now reflect current state of instance (#1366) (409d35b)
- tolerate null prototype for config objects with
extends
(#1376) (3d26d11), closes #1372 - yargs.parsed now populated before returning, when yargs.parse() called with no args (#1382) (e3981fd), closes #1382
- adds support for multiple epilog messages (#1384) (07a5554)
- allow completionCommand to be set via showCompletionScript (#1385) (5562853)
13.3.0 (2019-06-10)
- i18n: swap out os-locale dependency for simple inline implementation (#1356) (4dfa19b)
- support defaultDescription for positional arguments (812048c)
13.2.4 (2019-05-13)
13.2.3 (2019-05-05)
- deps: upgrade cliui for compatibility with latest chalk. (#1330) (b20db65)
- address issues with dutch translation (#1316) (0295132)
13.2.2 (2019-03-06)
13.2.1 (2019-02-18)
13.2.0 (2019-02-15)
13.1.0 (2019-02-12)
- add applyBeforeValidation, for applying sync middleware before validation (5be206a)
13.0.0 (2019-02-02)
- deps: Update os-locale to avoid security vulnerability (#1270) (27bf739)
- validation: Use the error as a message when none exists otherwise (#1268) (0510fe6)
- better bash path completion (#1272) (da75ea2)
- middleware added multiple times due to reference bug (#1282) (64af518)
drop Node 6 from testing matrix (#1287) (ef16792)- opting to not drop Node 6 support until April, see.
- update dependencies (#1284) (f25de4f)
- Add
.parserConfiguration()
method, deprecating package.json config (#1262) (3c6869a) - adds config option for sorting command output (#1256) (6916ce9)
- options/positionals with leading '+' and '0' no longer parse as numbers (#1286) (e9dc3aa)
- support promises in middleware (f3a4e4f)
- options with leading '+' or '0' now parse as strings
- dropping Node 6 which hits end of life in April 2019
- see [email protected] CHANGELOG
- we now warn if the yargs stanza package.json is used.
12.0.5 (2018-11-19)
12.0.4 (2018-11-10)
- don't load config when processing positionals (5d0dc92)
12.0.3 (2018-10-06)
- $0 contains first arg in bundled electron apps (#1206) (567820b)
- accept single function for middleware (66fd6f7), closes #1214 #1214
- hide
hidden
options from help output even if they are in a group (#1221) (da54028) - improve Norwegian Bokmål translations (#1208) (a458fa4)
- improve Norwegian Nynorsk translations (#1207) (d422eb5)
12.0.2 (2018-09-04)
- middleware should work regardless of when method is called (664b265), closes #1178
- translation not working when using __ with a single parameter (#1183) (f449aea)
- upgrade os-locale to version that addresses license issue (#1195) (efc0970)
12.0.1 (2018-06-29)
12.0.0 (2018-06-26)
- .argv and .parse() now invoke identical code path (#1126) (f13ebf4)
- remove the trailing white spaces from the help output (#1090) (3f0746c)
- completion: Avoid default command and recommendations during completion (#1123) (036e7c5)
- test Node.js 6, 8 and 10 (#1160) (84f9d2b)
- upgrade to version of yargs-parser that does not populate value for unset boolean (#1104) (d4705f4)
- add support for global middleware, useful for shared tasks like metrics (#1119) (9d71ac7)
- allow setting scriptName $0 (#1143) (a2f2eae)
- remove
setPlaceholderKeys
(#1105) (6ee2c82)
- Options absent from
argv
(not set via CLI argument) are now absent from the parsed result object rather than being set withundefined
- drop Node 4 from testing matrix, such that we'll gradually start drifting away from supporting Node 4.
- yargs-parser does not populate 'false' when boolean flag is not passed
- tests that assert against help output will need to be updated
11.1.0 (2018-03-04)
- allow hidden options to be displayed with --show-hidden (#1061) (ea862ae)
- extend *.rc files in addition to json (#1080) (11691a6)
11.0.0 (2018-01-22)
- requiresArg now has significantly different error output, matching nargs.
10.1.2 (2018-01-17)
10.1.1 (2018-01-09)
10.1.0 (2018-01-01)
- add missing simple chinese locale strings (#1004) (3cc24ec)
- add Norwegian Nynorsk translations (#1028) (a5ac213)
- async command handlers (#1001) (241124b)
- middleware (#881) (77b8dbc)
10.0.3 (2017-10-21)
10.0.2 (2017-10-21)
10.0.1 (2017-10-19)
- help strings for nested commands were missing parent commands (#990) (cd1ca15)
- use correct completion command in generated completion script (#988) (3c8ac1d)
10.0.0 (2017-10-18)
- config and normalize can be disabled with false (#952) (3bb8771)
- less eager help command execution (#972) (8c1d7bf)
- the positional argument parse was clobbering global flag arguments (#984) (7e58453)
- .usage() can now be used to configure a default command (#975) (7269531)
- hidden options are now explicitly indicated using "hidden" flag (#962) (280d0d6)
- introduce .positional() for configuring positional arguments (#967) (cb16460)
- replace $0 with file basename (#983) (20bb99b)
- .usage() no longer accepts an options object as the second argument. It can instead be used as an alias for configuring a default command.
- previously hidden options were simply implied using a falsy description
- help command now only executes if it's the last positional in argv._
9.1.0 (2017-09-25)
9.0.1 (2017-09-17)
9.0.0 (2017-09-03)
- 'undefined' default value for choices resulted in validation failing (782b896)
- address bug with handling of arrays of implications (c240661)
- defaulting keys to 'undefined' interfered with conflicting key logic (a8e0cff)
- don't bother calling JSON.stringify() on string default values (#891) (628be21)
- exclude positional arguments from completion output (#927) (71c7ec7)
- strict mode should not fail for hidden options (#949) (0e0c58d)
- allow implies and conflicts to accept array values (#922) (abdc7da)
- allow parse with no arguments as alias for yargs.argv (#944) (a9f03e7)
- enable .help() and .version() by default (#912) (1ef44e0)
- to allow both undefined and nulls, for benefit of TypeScript (#945) (792564d)
- version() and help() are now enabled by default, and show up in help output; the implicit help command can no longer be enabled/disabled independently from the help command itself (which can now be disabled).
- parse() now behaves as an alias for .argv, unless a parseCallback is provided.
8.0.2 (2017-06-12)
8.0.1 (2017-05-02)
8.0.0 (2017-05-01)
- commands are now applied in order, from left to right (#857) (baba863)
- help now takes precedence over command recommendation (#866) (17e3567)
- positional arguments now work if no handler is provided to inner command (#864) (e28ded3)
- allow extends to inherit from a module (#865) (89456d9)
- allow strict mode to be disabled (#840) (6f78c05)
- extends functionality now always loads the JSON provided, rather than reading from a specific key
- Node 4+ is now required; this will allow us to start updating our dependencies.
- the first argument to strict() is now used to enable/disable its functionality, rather than controlling whether or not it is global.
7.1.0 (2017-04-13)
- fix demandOption no longer treats 'false' as truthy (#829) (c748dd2)
- get terminalWidth in non interactive mode no longer causes a validation exception (#837) (360e301)
- we shouldn't output help if we've printed a prior help-like message (#847) (17e89bd)
7.0.2 (2017-03-10)
- populating placeholder arguments broke validation (b3eb2fe)
7.0.1 (2017-03-03)
7.0.0 (2017-02-26)
- address min/max validation message regression (#750) (2e5ce0f)
- address positional argument strict() bug introduced in #766 (#784) (a8528e6)
- console.warn() rather than throwing errors when api signatures are incorrect (#804) (a607061)
- context should override parsed argv (#786) (0997288)
- context variables are now recognized in strict() mode (#796) (48575cd)
- errors were not bubbling appropriately from sub-commands to top-level (#802) (8a992f5)
- positional arguments of sub-commands threw strict() exception (#805) (f3f074b)
- pull in yargs-parser with modified env precedence (#787) (e0fbbe5)
- running parse() multiple times on the same yargs instance caused exception if help() enabled (#790) (07e39b7)
- use path.resolve() to support node 0.10 (#797) (49a93fc)
- add conflicts and implies shorthands. (#753) (bd1472b)
- add traditional Chinese translation (#780) (6ab6a95)
- allow provided config object to extend other configs (#779) (3280dd0)
- function argument validation (#773) (22ed9bb)
- if only one column is provided for examples, allow it to take up the entire line (#749) (7931652)
- introduce custom yargs error object (#765) (8308efa)
- introduces support for default commands, using the '*' identifier (#785) (d78a0f5)
- rethink how options are inherited by commands (#766) (ab1fa4b)
extends
key in config file is now used for extending other config files- environment variables now take precedence over config files.
- context now takes precedence over argv and defaults
- the arguments passed to functions are now validated, there's a good chance this will throw exceptions for a few folks who are using the API in an unexpected way.
- by default options, and many of yargs' parsing helpers will now default to being applied globally; such that they are no-longer reset before being passed into commands.
- yargs will no longer aggressively suppress errors, allowing errors that are not generated internally to bubble.
6.6.0 (2016-12-29)
- [object Object] was accidentally being populated on options object (#736) (f755e27)
- do not use cwd when resolving package.json for yargs parsing config (#726) (9bdaab7)
- implement conflicts() for defining mutually exclusive arguments; thanks @madcampos! (#741) (5883779)
- split demand() into demandCommand()/demandOption() (#740) (66573c8)
- support for positional argument aliases (#727) (27e1a57)
6.5.0 (2016-12-01)
6.4.0 (2016-11-13)
- locales: Added Belarusian translation (#690) (68dac1f)
- locales: Create nl.json (#687) (46ce1bb)
- update to yargs-parser that addresses #598, #617 (#700) (54cb31d)
- yargs is now passed as the third-argument to fail handler (#613) (21b74f9)
6.3.0 (2016-10-19)
6.2.0 (2016-10-16)
- add new pt_BR translations (#674) (5615a82)
- Italian translations for 'did you mean' and 'aliases' (#673) (81984e6)
6.1.1 (2016-10-15)
- freeze was not resetting configObjects to initial state; addressed performance issue raised by @nexdrew. (#670) (ae4bcd4)
6.1.0 (2016-10-15)
- locales: change some translations (#667) (aa966c5)
- locales: conform hi locale to y18n.__n expectations (#666) (22adb18)
- initial support for command aliases (#647) (127a040)
- command: add camelcase commands to argv (#658) (b1cabae)
- locales: add Hindi translations (9290912)
- locales: add Hungarian translations (be92327)
- locales: Japanese translations for 'did you mean' and 'aliases' (#651) (5eb78fc)
- locales: Polish translations for 'did you mean' and 'aliases' (#650) (c951c0e)
- reworking yargs API to make it easier to run in headless environments, e.g., Slack (#646) (f284c29)
- Turkish translations for 'did you mean' and 'aliases' (#660) (072fd45)
6.0.0 (2016-09-30)
- changed parsing of the command string to ignore extra spaces (#600) (e8e5a72)
- drop lodash.assign (#641) (ad3146f)
- for args that have skipValidation set to
true
, check if the parsed arg istrue
(#619) (658a34c) - upgrade standard, and fix appveyor config so that it works with newest standard (#607) (c301f42)
- coerce is now applied as a final step after other parsing is complete
5.0.0 (2016-08-14)
- default: Remove undocumented alias of default() (#469) (b8591b2)
- remove deprecated zh.json (#578) (317c62c)
- .help() API can now enable implicit help command (#574) (7645019)
- command: builder function no longer needs to return the yargs instance (#549) (eaa2873)
- add coerce api (#586) (1d53ccb)
- adds recommendCommands() for command suggestions (#580) (59474dc)
- apply .env() globally (#553) (be65728)
- apply default builder to command() and apply fail() handlers globally (#583) (0aaa68b)
- update yargs-parser to version 3.1.0 (#581) (882a127)
- fail is now applied globally.
- we now default to an empty builder function when command is executed with no builder.
- yargs-parser now better handles negative integer values, at the cost of handling numeric option names, e.g., -1 hello
- default: removed undocumented
defaults
alias fordefault
. - introduces a default
help
command which outputs help, as an alternative to a help flag. - interpret demand() numbers as relative to executing command (#582) (927810c)
4.8.1 (2016-07-16)
- commandDir: make dir relative to caller instead of require.main.filename (#548) (3c2e479)
- add config lookup for .implies() (#556) (8d7585c)
- cache pkg lookups by path to avoid returning the wrong one (#552) (fea7e0b)
- positional arguments were not being handled appropriately by parse() (#559) (063a866)
- pull in @nexdrew's fixes to yargs-parser (#560) (c77c080), closes #560
4.8.0 (2016-07-09)
- drop unused camelcase dependency fixes #516 (#525) (365fb9a), closes #516 #525
- fake a tty in tests, so that we can use the new set-blocking (#512) (a54c742)
- ignore invalid package.json during read-pkg-up (#546) (e058c87)
- keep both zh and zh_CN until yargs@5.x (0f8faa7)
- lazy-load package.json and cache. get rid of pkg-conf dependency. (#544) (2609b2e)
- we now respect the order of _ when applying commands (#537) (ed86b78)
- add .commandDir(dir) to API to apply all command modules from a relative directory (#494) (b299dff)
- command: derive missing command string from module filename (#527) (20d4b8a)
- builder is now optional for a command module (#545) (8d6ad6e)
4.7.1 (2016-05-15)
- switch to using
const
rather thanvar
(#499) - make stdout flush on newer versions of Node.js (#501) (9f8c6f4)
4.7.0 (2016-05-02)
- completion: allow to get completions for any string, not just process.argv (#470)(74fcfbc)
- configuration: Allow to directly pass a configuration object to .config() (#480)(e0a7e05)
- validation: Add .skipValidation() method (#471)(d72badb)
4.6.0 (2016-04-11)
- my brand!: I agree with @osher lightweight isn't a huge selling point of ours any longer, see #468 (c46d7e1)
- switch to standard-version for release management (f70f801)
- upgrade to version of yargs-parser that introduces some slick new features, great work @elas7. update cliui, replace win-spawn, replace badge. (#475) (f915dd4)
4.5.0 (2016-04-05)
- windows: handle $0 better on Windows platforms (eb6e03f)
- commands: implemented variadic positional arguments (51d926e)
- completion: completion now better handles aliases, and avoids duplicating keys. (86416c8)
- config: If invoking .config() without parameters, set a default option (0413dd1)
- conventional-changelog: switching to using conventional-changelog for generating the changelog (a2b5a2a)
- #454 fix demand() when second argument is an array (@elas7)
- #452 fix code example for
.help()
docs (@maxrimue) - #450 fix for bash completion trailing space edge-case (@elas7)
- #448 allow a method to be passed to
showHelp
, rather than a log-level (@osher) - #446 update yargs-parser, y18n, nyc, cliui, pkg-conf (@bcoe)
- #436 the rebase method is only used by tests, do not export it in two places (@elas7)
- #428 initial support for subcommands (@nexdrew)
- #445 strict mode was failing if no commands were registered (@nexdrew)
- #443 adds Italian translation \o/ (@madrisan)
- #441 remove duplicate keys from array options configuration (@elas7)
- #437 standardize tests for .command() (@lrlna)
- #432 non-singleton version of yargs (@bcoe)
- [#422, #425, #420] translations for number (@zkat, @rilut, @maxrimue, @watilde)
- #414 all command options can be defined in module now (@nexdrew)
- #395 do not reset groups if they contain global keys (@novemberborn)
- #393 use sane default for usage strings (@nexdrew)
- #392 resetting wrap() was causing layout issues with commands (@nexdrew)
- #391 commands were being added multiple times (@nexdrew)
- #384 add new number type to yargs (@lrlna, @maxrimue)
- #382 pass error as extra parameter to fail (@gajus)
- #378 introduces the pkgConf feature, which tells yargs to load default argument values from a key on a project's package.json (@bcoe)
- #376 breaking change, make help() method signature more consistent with other commands (@maxrimue)
- #368 breaking change, overhaul to command handling API: introducing named positional arguments, commands as modules, introduces the concept of global options (options that don't reset). (@nexdrew, @bcoe).
- #364 add the slick new yargs website to the package.json (@iarna).
- #357 .strict() now requires that a valid command is provided (@lrlna)
- #356 pull the parsing bits of yargs into the separate module yargs-parser. Various parsing options can now be turned on and off using configuration (@bcoe).
- #330 breaking change, fix inconsistencies with
.version()
API. (@maxrimue).
- #344 yargs now has a code of conduct and contributor guidelines (@bcoe)
- #341 Fix edge-case with camel-case arguments (@davibe)
- #331 Handle parsing a raw argument string (@kellyselden)
- #325 Tweaks to make tests pass again on Windows (@isaacs)
- #321 Custom config parsing function (@bcoe)
- #239 Pass argv to commands (@bcoe)
- #308 Yargs now handles environment variables (@nexdrew)
- #302 Add Indonesian translation (@rilut)
- #300 Add Turkish translation (@feyzo)
- #298 Add Norwegian Bokmål translation (@sindresorhus)
- #297 Fix for layout of cjk characters (@disjukr)
- #296 Add Korean translation (@disjukr)
- #293 Polish language support (@kamilogorek)
- #291 fix edge-cases with
.alias()
(@bcoe) - #289 group options in custom groups (@bcoe)
- #277 adds support for ansi escape codes (@bcoe)
- #271 skips validation for help or version flags with exitProcess(false) (@tepez)
- #273 implements single output for errors with exitProcess(false) (@nexdrew)
- #269 verifies single output for errors with exitProcess(false) (@tepez)
- #268 adds Chinese translation (@qiu8310)
- #266 adds case for -- after -- in parser test (@geophree)
- #263 document count() and option() object keys (@nexdrew)
- #259 remove util in readme (@38elements)
- #258 node v4 builds, update deps (@nexdrew)
- #257 fix spelling errors (@dkoleary88)
- #248 reinstate os-locale, no spawning (@nexdrew)
- #249 use travis container-based infrastructure (@nexdrew)
- #247 upgrade standard (@nexdrew)
- #246 detect locale based only on environment variables (@bcoe)
- #244 adds Windows CI testing (@bcoe)
- #245 adds OSX CI testing (@bcoe, @nexdrew)
- #242 adds detectLocale config option (@bcoe)
- #240 hot-fix for Atom on Windows (@bcoe)
- #238 upgrade camelcase, window-size, chai, mocha (@nexdrew)
- #237 adds defaultDescription to option() (@nexdrew)
- #231 Merge pull request #231 from bcoe/detect-locale (@sindresorhus)
- #235 adds german translation to yargs (@maxrimue)
- #224 added Portuguese translation (@codemonkey3045)
- #228 notes about embedding yargs in Electron (@etiktin)
- #223 make booleans work in config files (@sgentle)
- #222 updates fr locale (@nexdrew)
- #221 adds missing locale strings (@nexdrew)
- #220 adds es locale (@zkat)
- #218 upgrades nyc (@bcoe)
- #210 adds i18n support to yargs (@bcoe)
- #209 adds choices type to yargs (@nexdrew)
- #207 pretty new shields from shields.io (@SimenB)
- #208 improvements to README.md (@nexdrew)
- #205 faster build times on Travis (@ChristianMurphy)
- #197 tweaks to how errors bubble up from parser.js (@bcoe)
- #193 upgraded nyc, reporting now happens by default (@bcoe)
- #192 standard style nits (@bcoe)
- #190 allow for hidden commands, e.g., .completion('completion', false) (@tschaub)
- #187 completion now behaves differently if it is being run in the context of a command (@tschaub)
- #186 if no matches are found for a completion default to filename completion (@tschaub)
- #183 don't complete commands if they've already been completed (@tschaub)
- #181 various fixes for completion. (@bcoe, @tschaub)
- #182 you can now set a maximum # of of required arguments (@bcoe)
- #173 update standard, window-size, chai (@bcoe)
- #171 a description can now be set when providing a config option. (@5c077yP)
- #165 expose yargs.terminalWidth() thanks @ensonic (@bcoe)
- #164 better array handling thanks @getify (@bcoe)
- b6662b6 clarify .config() docs (@linclark)
- 0291360 fixed tests, switched to nyc for coverage, fixed security issue, added Lin as collaborator (@bcoe)
- #157 Merge pull request #157 from bcoe/command-yargs. allows handling of command specific arguments. Thanks for the suggestion @ohjames (@bcoe)
- #158 Merge pull request #158 from kemitchell/spdx-license. Update license format (@kemitchell)
- #154 showHelp's method signature was misleading fixes #153 (@bcoe)
- #151 refactor yargs' table layout logic to use new helper library (@bcoe)
- #150 Fix README example in argument requirements (@annonymouse)
- 679fbbf updated yargs to use the standard style guide (agokjr)
- [22382ee](https://github.com/bcoe/yargs/commit/22382ee9f5b495bc2586c1758cd1091cec3647f9 various bug fixes for $0 (@nylen)
- 89e1992 detect iojs bin along with node bin. (@bcoe)
- 755509e improvements to example documentation in README.md (@rstacruz)
- 0d2dfc8 showHelp() no longer requires that .argv has been called (@bcoe)
- 56cbe2d make .requiresArg() work with type hints. (@bcoe).
- 2f5d562 serialize arrays and objects in usage strings. (@bcoe).
- 5126304 be more lenient about alias/primary key ordering in chaining API. (@bcoe)
- 4e24e22 support for .js configuration files. (@pirxpilot)
- c16cc08 message for non-option arguments is now optional, thanks to (@raine)
- 870b428 completion script was missing in package.json (@bcoe)
- 58a4b24 parse was being called multiple times, resulting in strange behavior (@bcoe)
- 4e588e0 accidentally left testing logic in (@bcoe)
- 718bacd added support for bash completions see #4 (@bcoe)
- a192882 downgrade to mocha 2.1.0 until mochajs/mocha#1585 can be sorted out (@bcoe)
- 9845e5c the Argv singleton was not being updated when manually parsing arguments, fixes #114 (@bcoe)
- 45b4c80 set placeholders for all keys fixes #115 (@bcoe)
- a758e0b fix for count consuming too many arguments (@bcoe)
- 0476af7 added nargs feature, allowing you to specify the number of arguments after an option (@bcoe)
- 092477d updated README with full example of v3.0 API (@bcoe)
- 0c4b769 remove string dependency, which conflicted with other libraries see #106 (@bcoe)
- 2a98906 add $0 to epilog (@schnittstabil)
- ad485ce fix for applying defaults to camel-case args (@bcoe)
- 8bfe36d fix and document restart() command, as a tool for building nested CLIs (@bcoe)
- 49a6d18 you can now provide a function that generates a default value (@bcoe)
- 7a55886 improvements to yargs two-column text layout (@bcoe)
- b6ab513 Tweak NPM version badge (@nylen)
- 9bd2379 version now accepts a function, making it easy to load version #s from a package.json (@bcoe)
- 0b7c19b various fixes for dot-notation handling (@bcoe)
- c3f35e9 make sure dot-notation is applied to aliases (@bcoe)
- 74c8967 document epilog shorthand of epilogue. (@bcoe)
- 670110f any non-truthy value now causes check to fail see #76 (@bcoe)
- 0d8f791 finished implementing my wish-list of fetures for yargs 3.0. see #88 (@bcoe)
- 5768447 fix coverage. (@bcoe)
- 82e793f detect console width and perform word-wrapping. (@bcoe)
- 67476b3 refactor two-column table layout so that we can use it for examples and usage (@bcoe)
- 4724cdf major refactor of index.js, in prep for 3.x release. (@bcoe)
- d824620 allow for undefined boolean defaults (@ashi009)
- d6edd98 in-prep for further refactoring, and a 3.x release I've shuffled some things around and gotten test-coverage to 100%. (@bcoe)
- d640745 switch to path.relative (@bcoe)
- 3bfd41f remove mocha.opts. (@bcoe)
- 47a2f35 document using .string('_') for string ids. see #56 (@bcoe)
- #57 Merge pull request #57 from eush77/option-readme (@eush77)
- 01c6c61 fix for #71, 'newAliases' of undefined (@bcoe)
- 6a1a3fa try to guess argument types, and apply sensible defaults see #73 (@bcoe)
- 96a06b2 Fix for strange behavior with --sort option, see #51 (@bcoe)
- 0250517 - 108fb84 fixed bug with boolean parsing, when bools separated by = see #66 (@bcoe)
- a465a59 Add
files
field to the package.json (@shinnn) - 31043de fix for yargs.argv having the same keys added multiple times see #63 (@bcoe)
- 2d68c5b Disable process.exit calls using .exitProcess(false) (@cianclarke)
- 45da9ec Mention .option in README (@eush77)
- b8d3472 1.3.2 (@chevex)
- fbc777f Now that yargs is the successor to optimist, I'm changing the README language to be more universal. Pirate speak isn't very accessible to non-native speakers. (@chevex)
- a54d068 version output will not print extra newline (@boneskull)
- 1cef5d6 Added contributors section to package.json (@chrisn)
- cc295c0 Added 'require' and 'required' as synonyms for 'demand' (@chrisn)
- d0bf951 Updating minimist. (@chevex)
- c15f8e7 Fix #31 (bad interaction between camelCase options and strict mode) (@nylen)
- d991b9b Added .help() and .version() methods (@chrisn)
- e8c8aa4 Added .showHelpOnFail() method (@chrisn)
- e855af4 Allow boolean flag with .demand() (@chrisn)
- 14dbec2 Fixes issue #22. Arguments are no longer printed to the console when using .config. (@chevex)
- bef74fc Informing users that Yargs is the official optimist successor. (@chevex)
- #24 Merge pull request #24 from chrisn/strict (@chrisn)
- 889a2b2 Added requiresArg option, for options that require values (@chrisn)
- eb16369 Added .strict() method, to report error if unknown arguments are given (@chrisn)
- 0471c3f Changed optimist to yargs in usage-options.js example (@chrisn)
- 5c88f74 Change optimist to yargs in examples (@chrisn)
- 66f12c8 Fix a couple of bad interactions between aliases and defaults (@nylen)
- 8fa1d80 Document second argument of usage(message, opts) (@Gobie)
- 56e6528 For "--some-option", also set argv.someOption (@nylen)
- ed5f6d3 Finished porting unit tests to Mocha. (@chevex)
- e2b1fc0 1.0.15 update to badges (@chevex)
- f33bbb0 Revert "Fixed issue which caused .demand function not to work correctly." (@chevex)
- 6509e5e Fixed issue which caused .demand function not to work correctly. (@chevex)
- 05eb267 1.0.12 (@chevex)
- c1bde46 1.0.11 (@chevex)
- dfebf81 Fixed formatting in README (@chevex)
- 0b4e34a Update README.md (@chevex)
- #1 fix error caused by check() see #1 (@martinheidegger)
- a247d88 Modified Pirate Joe image. (@chevex)
- d7f69e1 Updated Pirate Joe image. (@chevex)
- ece809c Updated readme notice again. (@chevex)
- 9e81e81 Updated README with a notice about yargs being a fork of optimist and what that implies. (@chevex)
- 65e7a78 Changed some small wording in README.md. (@chevex)
- 459e20e Fix a bug in the options function, when string and boolean options weren't applied to aliases. (@shockone)
- 3d80ebe 1.0.2 (@chevex)
- f80ff36 Updated image. (@chevex)
- 54e31d5 Rebranded from optimist to yargs in the spirit of the fork :D (@chevex)
- 4ebb6c5 Added documentation for demandCount(). (@chevex)
- 4561ce6 Simplified the error messages returned by .check(). (@chevex)
- 661c678 Fixed an issue with demand not accepting a zero value. (@chevex)
- 731dd3c Add .fail(fn) so death isn't the only option. Should fix issue #39. (@chevex)
- fa15417 Added a few missing 'return self' (@chevex)
- e655e4d Fix showing help in certain JS environments. (@chevex)
- a746a31 Better string representation of default values. (@chevex)
- 6134619 Implies: conditional demands (@chevex)
- 046b93b Added support for JSON config files. (@chevex)
- a677ec0 Add .example(cmd, desc) feature. (@chevex)
- 1bd4375 Added 'defaults' as alias to 'default' so as to avoid usage of a reserved keyword. (@chevex)
- 6b753c1 add .normalize(args..) support for normalizing paths (@chevex)
- 33d7d59 Customize error messages with demand(key, msg) (@chevex)
- 647d37f Merge branch 'rewrite-duplicate-test' of github.com:isbadawi/node-optimist (@chevex)
- 9059d1a Pass aliases object to check functions for greater versatility. (@chevex)
- 623dc26 Added ability to count boolean options and rolled minimist library back into project. (@chevex)
- 49f0dce Fixed small typo. (@chevex)
- 79ec980 Removed dependency on wordwrap module. (@chevex)
- ea14630 Merge branch 'master' of github.com:chbrown/node-optimist (@chevex)
- 2b75da2 Merge branch 'master' of github.com:seanzhou1023/node-optimist (@chevex)
- d9bda11 Merge branch 'patch-1' of github.com:thefourtheye/node-optimist (@chevex)
- d6cc606 Renamed README. (@chevex)
- 9498d3f Renamed readme and added .gitignore. (@chevex)
- bbd1fe3 Included examples for
help
andshowHelp
functions and fixed few formatting issues (@thefourtheye) - 37fea04 .alias({}) behaves differently based on mapping direction when generating descriptions (@chbrown)
- 855b20d Documented function signatures are useful for dynamically typed languages. (@chbrown)
- d37bfe0 all tests passing using minimist (@substack)
- 76f1352 all parse tests now passing (@substack)
- a7b6754 using minimist, some tests passing (@substack)
- 6655688 Give credit where its due (@DeadAlready)
- 602a2a9 v0.5.3 - Remove wordwrap as dependency (@DeadAlready)
- 4497ca5 fixed the whitespace bug without breaking anything else (@substack)
- 5a3dd1a failing test for whitespace arg (@substack)
- a20228f fix parse() to work with functions before it (@substack)
- b13bd4c failing test for parse() with modifiers (@substack)
- c474a64 fixes for dash (@substack)
- dafe3e1 failing short test (@substack)
- 6c7a0ec Fix for windows. On windows there is no _ in environment. (@hdf)
- e72346a Add support for newlines in -a="" arguments (@danielbeardsley)
- 71e1fb5 drop 0.4, add 0.8 to travis (@substack)
- f28c0e6 bump for string "true" params (@substack)
- 8f44aeb Fix failing test for aliased booleans. (@coderarity)
- b9f7b61 Add failing test for short aliased booleans. (@coderarity)
- 541bac8 Fixes #37.
- 3a0f014 travis badge (@substack)
- 4fb60bf Fix boolean aliases. (@coderarity)
- f14dda5 Adjusted package.json to use tap (@jfhbrook)
- 88e5d32 test/usage.js no longer hangs (@jfhbrook)
- e1e740c two tests for combined boolean/alias opts parsing (@jfhbrook)
- d09b719 If "default" is set to false it was not passed on, fixed. (@wolframkriesing)
- 6e74aa7 bump and documented dot notation (@substack)
- 94adee2 argv._ can be told 'Hey! argv._! Don't be messing with my args.', and it WILL obey (@colinta)
- c46fdd5 optimistic critter image (@substack)
- 5c95c73 alias options() to option() (@substack)
- f7692ea [fix] Fix for parsing boolean edge case (@indexzero)
- d1f92d1
- b01bda8 [fix test] Update to ensure optimist is aware of default booleans. Associated tests included (@indexzero)
- aa753e7 [dist test] Update devDependencies in package.json. Update test pathing to be more npm and require.paths future-proof (@indexzero)
- 7bfce2f s/sys/util/ (@substack)
- d420a7a update usage output (@substack)
- cf86eed some sage readme protips about parsing rules (@substack)
- 5da9f7a documented all the methods finally (@substack)
- 8ca6879 fenced syntax highlighting (@substack)
- b72bacf right-alignment of wrapped extra params (@substack)
- 2b980bf now with .wrap() (@substack)
- d614f63 don't show 'Options:' when there aren't any (@substack)
- 691eda3 failing test for multi-aliasing (@substack)
- 0826c9f "Options:" > "options:" (@substack)
- 72f7490 [minor] Update formatting for
.showHelp()
(@indexzero) - 75aecce options works again, too lazy to write a proper test right now (@substack)
- f742e54 line_count_options example, which breaks (@substack)
- 4ca06b8 line count example (@substack)
- eeb8423 remove self.argv setting in boolean (@substack)
- 6903412 removed camel case for now (@substack)
- 5a0d88b remove dead longest checking code (@substack)
- d782170 .help() too (@substack)
- 622ec17 rm old help generator (@substack)
- 7c8baac nub keys (@substack)
- 8197785 generate help message based on the previous calls, todo: nub (@substack)
- 3ffbdc3 stub out new showHelp, better checks (@substack)
- d4e21f5 let .options() take single options too (@substack)
- 3c4cf29 .options() is now heaps simpler (@substack)
- 89f0d04 defaults work again, all tests pass (@substack)
- dd87333 update test error messages, down to 2 failing tests (@substack)
- 53f7bc6 fix for bools doubling up, passes the parse test again, others fail (@substack)
- 2213e2d refactored for an argv getter, failing several tests (@substack)
- d1e7379 just rescan for now, alias test passes (@substack)
- b2f8c99 failing alias test (@substack)
- d0c0174 .alias() (@substack)
- d85f431 [api] Remove
.describe()
in favor of building upon the existing.usage()
API (@indexzero) - edbd527 [doc api] Add
.describe()
,.options()
, and.showHelp()
methods along with example. (@indexzero) - be4902f updates for coffee since it now does argv the node way (@substack)
- e24cb23 more general coffeescript detection (@substack)
- 78ac753 Don't trigger the CoffeeScript hack when running under node_g. (@papandreou)
- bcfe973 .string() but failing test (@substack)
- 1987aca test hex strings (@substack)
- ef36db3 more keywords (@substack)
- cc53c56 Added camelCase function that converts --multi-word-option to camel case (so it becomes argv.multiWordOption). (@papandreou)
- 60b57da fixed boolean bug by rescanning (@substack)
- dff6d07 boolean examples (@substack)
- 0e380b9 boolean() with passing test (@substack)
- 62644d4 coffee compatibility with node regex for versions too (@substack)
- 430fafc argv._ fixed by fixing the coffee detection (@substack)
- 343b8af whichNodeArgs test fails too (@substack)
- 63df2f3 replicated mnot's bug in whichNodeEmpty test (@substack)
- 35473a4 test for ./bin usage (@substack)
- 13df151 don't coerce booleans to numbers (@substack)
- 85f8007 package bump for automatic number conversion (@substack)
- 8f17014 updated readme and examples with new auto-numberification goodness (@substack)
- 73dc901 auto number conversion works yay (@substack)
- bcec56b failing test for not-implemented auto numification (@substack)
- ebd2844 odd that eql doesn't check types careflly (@substack)
- fd854b0 package author + keywords (@substack)
- 656a1d5 updated readme with .default() stuff (@substack)
- cd7f8c5 passing tests for new .default() behavior (@substack)
- 932725e new default() thing for setting default key/values (@substack)
- 4e6c7ab test for coffee usage (@substack)
- d54ffcc new --key value style with passing tests. NOTE: changes existing behavior (@substack)
- ed2a2d5 package bump for summatix's coffee script fix (@substack)
- 75a975e Added support for CoffeeScript (@summatix)
- 56b2b1d test coverage for the falsy check() usage (@substack)
- a4843a9 check bug fixed plus a handy string (@substack)
- 857bd2d tests for demandCount, back up to 100% coverage (@substack)
- 073b776 call demandCount from demand (@substack)
- 4bd4b7a add demandCount to check for the number of arguments in the _ list (@marshall)
- b8689ac Rebase checks. That will be its own module eventually. (@substack)
- e688370 a $0 like in perl (@substack)
- 2e5e196 usage test hacking around process and console (@substack)
- fcc3521 description pun (@substack)
- 87a1fe2 mit/x11 license (@substack)
- 8d089d2 bool example is more consistent and also shows off short option grouping (@substack)
- 448d747 start of the readme and examples (@substack)
- da74dea more tests for long and short captures (@substack)
- ab6387e silly bug in the tests with s/not/no/, all tests pass now (@substack)
- 102496a hack an instance for process.argv onto Argv so the export can be called to create an instance or used for argv, which is the most common case (@substack)
- a01caeb divide example (@substack)
- 443da55 start of the lib with a package.json (@substack)