base library for oclif CLIs
Last release 7 days ago
19 Aug 2026
Ships fairly regularly
a new release about every 2 weeks
Nearly every release is documented
notes for 60 of the last 60 stable releases
Nothing withdrawn
no release was ever pulled
6 years old
478 releases · first in 2020
Release timeline
478 releases since 2020Releases
- 4.0.0-beta.222 Apr 2024pre-release
- 4.0.0-beta.118 Apr 2024pre-release
Nothing published for this version
- 3.27.04 Jun 2024
Release notes
Open source → - 3.26.93 Jun 2024
Release notes2 sources agree
Open source → - 3.26.83 Jun 2024
Release notes2 sources agree
Open source → - 3.26.73 Jun 2024
- 3.26.66 May 2024
Release notes2 sources agree
Open source → - 3.26.530 Apr 2024
- 3.26.418 Apr 2024
Release notes2 sources agree
Open source → - 3.26.313 Apr 2024
- 3.26.28 Apr 2024
- 3.26.18 Apr 2024
- 3.26.022 Mar 2024
- 3.25.319 Mar 2024
Release notes2 sources agree
Open source → - 3.25.215 Mar 2024
Release notes2 sources agree
Open source → - 3.25.114 Mar 2024
Release notes
Open source →Additional notes
Open source →Bug Fixes
3.25.0 (2024-03-12)
Features
3.24.0 (2024-03-11)
Bug Fixes
- use correct prop name (a509fa4)
Features
- print ellipsis on arg if static is false (7a71524)
- 3.25.012 Mar 2024
- 3.24.011 Mar 2024
Release notes
Open source →Bug Fixes
- use correct prop name (a509fa4)
Features
- print ellipsis on arg if static is false (7a71524)
- 3.23.111 Mar 2024
- 3.23.05 Mar 2024
- 3.22.05 Mar 2024
- 3.21.24 Mar 2024
Release notes2 sources agree
Open source → - 3.21.14 Mar 2024
- 3.21.04 Mar 2024
Release notes
Open source →Features
Command Discovery Strategies
Support three strategies for command discovery:
pattern- this is the current behavior that finds commands based on glob patternsexplicit- find commands that are exported from a specified file. This is to support developers who wish to bundle their CLI into a single file.single- CLI contains a single command executed by top-level bin
patternStrategyFor
pattern, plugins could continue to do this:{ "oclif": { "commands": "./dist/commands", } }which will tell oclif to look for commands in that directory (this is skipped if an
oclif.manifest.jsonis present)Alternatively, plugins could set this configuration:
{ "oclif": { "commands": { "strategy": "pattern", "target": "./dist/commands" } } }And they could even add
globPatternsto override the glob patterns that oclif uses when searching for command files:{ "oclif": { "commands": { "strategy": "pattern", "target": "./dist/commands", "globPatterns": [ "**/*.+(js|cjs|mjs|ts|tsx|mts|cts)", "!**/*.+(d.*|test.*|spec.*|helpers.*)?(x)" ] } } }explicitStrategyFor
explicit, plugins would add a new file (e.g.src/commands.ts) and then add this configuration to the package.json{ "oclif": { "commands": { "strategy": "explicit", "target": "./dist/index.js", "identifier": "COMMANDS", } } }src/index.tswould then need to have an export with the same name as theidentifier(if not set, it defaults todefault) that's an object of command names to command classes, e.g.import Hello from './commands/hello' import HelloWorld from './commands/hello/world' export const COMMANDS = { hello: Hello, 'hello:world': HelloWorld, howdy: Hello, // alias the `hello` command to `howdy` }The
explicitstrategy is useful to those who can't rely on file paths because they've bundled their code (https://github.com/oclif/oclif/issues/653) but it can also be used if you simply prefer to be more explicit about your commands instead of relying on oclif "magically" finding commands from the file system.It can also be leveraged to create or modify commands at runtime (e.g. add flags to a command based on an API spec - see
oclif + dynamic commandssection below).Unfortunately, there is no notable performance improvement for development since most of the time is spent auto-transpiling typescript with ts-node
singleStrategyThis strategy is for single command CLIs, i.e. CLIs whose bin invokes a single command.
The current way to achieve this to set this in the package.json
{ "oclif": { "default": ".", "commands": "./dist", } }The
defaulttells oclif to use.as the command id when no command is found andcommandstells oclif where to find the command file. In the example,./distwill resolve to to./dist/index.jsThe
defaultproperty has always been a less-than-ideal workaround and will be deprecated in favor of these settings:{ "oclif": { "commands": { "strategy": "single", "target": "./dist" } } }Note about
oclif.manifest.jsonFor all strategies, the
oclif.manifest.jsonwill be used to load the commands instead of the default behavior of the strategy. - 3.20.1-dev.11 Mar 2024pre-release
Release notes
Open source →Bug Fixes
- make dir optional for execute (394cbc6)
Features
- allow pjson to be provided to Config (57fec8c)
- 3.20.1-dev.027 Feb 2024pre-release
Release notes
Open source →Bug Fixes
- only register command ids if they have valid cmd (488d4e2)
3.19.5-dev.0 (2024-02-21)
3.19.3-dev.0 (2024-02-16)
Bug Fixes
- update perf marker (0073a78)
3.19.2-dev.0 (2024-02-15)
Features
- bundle friendly (d0aa430)
3.19.2-qa.0 (2024-02-14)
Bug Fixes
Features
- 3.20.027 Feb 2024
Release notes
Open source → - 3.19.726 Feb 2024
- 3.19.623 Feb 2024
Release notes2 sources agree
Open source →Bug Fixes
- revert to original prompt implementation (a96e567)
- 3.19.522 Feb 2024
- 3.19.5-dev.021 Feb 2024pre-release
Release notes
Open source →3.19.3-dev.0 (2024-02-16)
Bug Fixes
- update perf marker (0073a78)
3.19.2-dev.0 (2024-02-15)
Features
- bundle friendly (d0aa430)
3.19.2-qa.0 (2024-02-14)
Bug Fixes
Features
- 3.19.421 Feb 2024
- 3.19.319 Feb 2024
Release notes2 sources agree
Open source → - 3.19.3-dev.016 Feb 2024pre-release
Release notes
Open source →Bug Fixes
- update perf marker (0073a78)
3.19.2 (2024-02-14)
Bug Fixes
- allow long text in ux.prompt (7d521b2)
- 3.19.214 Feb 2024
- 3.19.2-qa.014 Feb 2024pre-release
- 3.19.2-dev.015 Feb 2024pre-release
- 3.19.16 Feb 2024
- 3.19.05 Feb 2024
- 3.18.231 Jan 2024
- 3.18.110 Jan 2024
Additional notes
Open source →Bug Fixes
3.18.0 (2024-01-09)
Features
- no longer use tsconfck (79c4028)
3.17.0 (2024-01-09)
Features
- add node.options to pjson typings (#919) (42b113b), closes oclif/oclif#1238
3.16.0 (2024-01-02)
Features
- 3.18.09 Jan 2024
- 3.17.09 Jan 2024
Release notes
Open source →Features
- add node.options to pjson typings (#919) (42b113b), closes oclif/oclif#1238
- 3.16.02 Jan 2024
- 3.15.123 Dec 2023
Additional notes
Open source → - 3.15.015 Dec 2023
- 3.14.18 Dec 2023
Release notes
Open source → - 3.14.07 Dec 2023
- 3.13.24 Dec 2023
Release notes2 sources agree
Open source → - 3.13.130 Nov 2023
- 3.13.030 Nov 2023
- 3.12.130 Nov 2023
- 3.12.020 Nov 2023
- 3.11.1-dev.116 Nov 2023pre-release
- 3.11.1-dev.016 Nov 2023pre-release
Release notes
Open source →Bug Fixes
- change http to https in order to pass lockfile-check workflow (#869) (8cd05e4)
- https in yarn.lock (418d124)
- prepare for plugin-theme (31604f8)
- remove standardized id from usage string (cd746a6)
- streamline coloring (295dd30)
- support more chalk standards (0194eaa)
Features
- 3.11.013 Nov 2023
Release notes
Open source → - 3.10.88 Nov 2023
- 3.10.77 Nov 2023
- 3.10.66 Nov 2023
Release notes2 sources agree
Open source → - 3.10.56 Nov 2023