New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
9.0.0 release #1683
9.0.0 release #1683
Commits on Aug 6, 2021
-
Rework default program name, and searching for subcommands (#1571)
* Simplify how default program name found. Just use args. * Rework search for executable files * Adjust error messaging, still WIP * Add executableDir and use searching for subcommands * Wording improvements * Add TypeScript for nameFromFilename * Add new tests for name (and nameFromFilename) * Add TypeScript for executableDir * Start tests for subcommand search * Comment-out unused routine for lint, WIP * Refactor tests and skip launchable executable tests on Windows * Add notes on further tests * Filling out mock executable tests * Expand tests * Remove debugging and ToDo * Relative and absolute test for executableDir * Avoid memory leak warning * Fix relative search test * Separate and expand .name section in README. And some lint, remove trailing spaces et al * Add .name to multiple subcommand example * Update description of executable search. Add mention of .executableDir * Add coverage of naming subcommands.
Commits on Aug 25, 2021
Commits on Aug 26, 2021
-
Conditional exports to simplify ECMAScript import (#1589)
* FIrst try at exports in package.json * Set required version for conditional export in package.json * Update README with export support
Commits on Oct 25, 2021
Commits on Dec 18, 2021
Commits on Dec 21, 2021
-
Rework option defaults and add preset (#1652)
* Add defaultOption, but not implemented * Start refactoring addOption to clarify logic * Update comments * Implement separate default and preset for options * Changed behaviour of boolean default, fix and extend test * Update unit tests with new default/preset behaviour * Add tests for default with all option types * Add tests that default does get overwritten * Fix JSDoc for new routines * Add tests for preset * Add typings * Update README * Add test of preset with negated * Update comments * Add tests of options being used twice * Modify documentation for preset * Add prefix example usage in README * Add preset to help * Update code example * Use same format for preset as for default, add test * Be selective about default and preset shown in help
-
Throw error for Option to option() or requiredOption() (#1655)
* Throw error for wrong argument to option or requiredOption * Make test and error message more specific
-
-
Upgrade package-lock.json to lockfile@2 (#1659)
* Update package-lock.json to lockfile@2 * Update Jest * Update Jest * Update @types/node * Update standard
Commits on Dec 22, 2021
Commits on Dec 25, 2021
Commits on Dec 27, 2021
-
Refactor README examples into a QuickStart (#1665)
* Quick Start * Update comments * Update quick start examples so README and code match
Commits on Jan 3, 2022
-
Allow readonly array as parameter to .aliases(), .parse(), .parseAsyn…
…c() (#1669) * Make .aliases() param readonly * Make .parse() and .parseAsync() param readonly in TypeScript
Commits on Jan 4, 2022
-
Reconfigure standard and eslint (#1668)
* Add eslint-config-standard peer dependencies explicitly * Remove unused eslint customisation, closer to standard * Configure eslint with no-extra-semi, as per semistandard * Use standard-with-typescript again now installing dependencies * Fix linting for undefined property * Run js and rs lint by default for `npm run lint`
-
Allow readonly array as parameter of .choices() (#1667)
* Allow readonly array as parameter of .choices() Without `readonly`, readonly arrays cannot be passed as parameters. Example: https://www.typescriptlang.org/play?#code/GYVwdgxgLglg9mABMAjACgIYCcsC5EDOUWMYA5gNoC6AlIgN4C+AUKJLAsgEyY75YBTDABMEAGwCehYqUq0GLZhARFE2LCkQBeRBQDkGPVQDcSlVDU4u23QaNqCiZWCKnW6dShqngPT9-deLC4A3yCQ4yA * Add tests for .choices() typings * Take a defensive copy of .choices argument to make sure it's readonly * Expand choices tests to cover readonly contract (#1) * Use the defensive copy of the parameter of .choices() in parseArg Co-authored-by: John Gee <john@ruru.gen.nz>
-
Commits on Jan 11, 2022
-
Add support for getting merged options including globals (#1671)
* Proof of concept * Use separate method for optsWithGlobals * Add documentation * Add tests * Simplify description * Add example * Remove unused param
Commits on Jan 14, 2022
-
Add error() for displaying errors from client code (#1675)
* Refactor private _displayError() into public error() * add TypeScript * Add tests * Add to README * Tiny wording change
-
-
-