Commander.js is a Node.js package for building command-line interfaces (CLIs). It helps you define commands and options, parses command-line arguments into options and arguments, provides error handling for issues like unknown options, and includes an automated help system.
Project status
- Actively maintained: The upstream repo shows recent activity (latest upstream push on 2026-09-01), and there was a major v15 update published in 2026-05-29, with earlier 2026-02-21 pre-release, suggesting ongoing work rather than dormancy.
- Update cadence: Major changes landed relatively close together in 2026 (an ESM-only direction via v15.0.0-0 in Feb, then v15.0.0 in late May), followed by fewer visible published updates after May, though upstream activity continues into September.
AI summary generated
Recent updates
v15.0.0
Commander v15.0.0 is the ESM-only release, moving the implementation from CommonJS to ESM and requiring newer Node.js versions. The release also adjusts CLI option behavior for certain negated options and improves error/help messaging, while updating the project’s test setup and maintenance policy.
BreakingFeaturesv15.0.0-0
Commander 15.0.0-0 is a major release that switches the project to ESM-only and raises the minimum supported Node.js version. The release also includes a behavior correction around negatable boolean options (--no-*) and a change to error output to show excess command arguments.
BreakingFeaturesv14.0.3
Release v14.0.3 primarily updates project documentation and maintenance policy. The published release notes mention end-of-life policy adjustments, a typing clarification for `.outputHelp()`, and README wording improvements.
v14.0.2
Release v14.0.2 is primarily a small behavior adjustment to negative number auto-detection during argument parsing, plus a broad update of development dependencies. The code diff also shows a TypeScript declaration change for deprecated callback-based overloads, and some CI workflow action version bumps that are not mentioned in the release notes.
v14.0.1
v14.0.1 is a small maintenance release with mostly internal refactors for readability and parsing efficiency, plus a README markdown link fix. The core behavioral-relevant changes are in argument and option variadic collection internals, and a refactor of Command.parseOptions to process the provided args array in-place.
v14.0.0
Commander v14.0.0 adds configurable help grouping for options and commands, including per-item headings and default headings applied to subsequently added items. It also improves parsing to accept unescaped negative numbers as option-arguments and command-arguments. The release also enforces a Node.js v20+ requirement.
BreakingFeaturesv13.1.0
v13.1.0 adds support for a pair of long option flags in `.option()`, enabling a “shortish” alias like `.option('--ws, --workspace')`. The underlying option-flag parser (`lib/option.js`) was updated to support this new shape and to change how unsupported flag formats are validated and reported.
Featuresv13.0.0
v13.0.0 adds support for calling .parse() multiple times with default settings, backed by new saveStateBeforeParse() and restoreStateBeforeParse() APIs intended for subclass customization. It also enhances help styling and adds help width/wrapping related methods, while introducing several documented breaking changes around argument handling and stricter option parsing.
BreakingFeaturesv13.0.0-0
This release refactors Commander help output to support styling and color-aware wrapping, introducing new Help primitives (like boxWrap, formatItem, and displayWidth) and new styling hooks. It also includes two documented breaking behavioral changes: excess command-arguments now error by default, and invalid option flag formats now throw during Option construction.
BreakingFeaturesv12.1.0
v12.1.0 adds improved argument parsing ergonomics by auto-detecting special Node.js options (such as `node --eval` and `node --print`) when `.parse()` is called with no arguments. It also modernizes the repo tooling (Prettier formatting, ESLint config changes), and extends security support for the previous major version of Commander.
BreakingSecurityFeatures