Skip to content

Commit

Permalink
Support custom help classes. (#523)
Browse files Browse the repository at this point in the history
Co-authored-by: Mike Donnalley <mdonnalley@salesforce.com>
  • Loading branch information
DanHulton and mdonnalley authored Jan 10, 2024
1 parent 2c9bd5b commit f240617
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/commands/help.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import {Args, Command, Flags, Help} from '@oclif/core'
import {Args, Command, Flags, loadHelpClass} from '@oclif/core'

export default class HelpCommand extends Command {
static args = {
Expand All @@ -18,6 +18,7 @@ export default class HelpCommand extends Command {

async run(): Promise<void> {
const {argv, flags} = await this.parse(HelpCommand)
const Help = await loadHelpClass(this.config);
const help = new Help(this.config, {all: flags['nested-commands']})
await help.showHelp(argv as string[])
}
Expand Down

0 comments on commit f240617

Please sign in to comment.