OptionalargsThe options for parsing command line arguments.
This is passed to the minimist library.
If these options do not include --help or --version, clirk will take
care of this and also take over if the flags are present.
OptionaldescriptionThe description of the CLI. If not provided, it will be derived from the CLI's package.json. Use an array of strings for multiple lines to support indentation.
OptionalexamplesUsage examples for the CLI. Use an array of strings for multiple lines to support indentation. Defaults to the command name.
OptionaliconAn optional icon for the CLI. This will be displayed in the help message.
The import.meta.dirname from any script within the CLI package.
This is used to resolve the CLI package information.
OptionalnameThe command name to run the CLI.
OptionaloptionsOptions for the CLI. This defines the supported options for the CLI for help messages. The keys are the names of the options, and the values are their descriptions. Use an array of strings for multiple lines to support indentation.
OptionaloptionsA label for the options section. If not provided, it will default to "OPTIONS". This is used in the help message to indicate the options section.
OptionalparametersParameters for the CLI. (Arguments that are not options.) This defines the supported parameters for the CLI for help messages. The keys are the names of the parameters, and the values are their descriptions. Use an array of strings for multiple lines to support indentation.
OptionalparametersA label for the parameters section. If not provided, it will default to "PARAMETERS". This is used in the help message to indicate the parameters section.
OptionalsigintA function to handle the SIGINT signal (Ctrl+C).
If provided, this function will be called when the user presses Ctrl+C.
If not provided, clirk will handle the SIGINT signal and exit gracefully.
The default message can be customized using the sigintMessage option.
If set to false, clirk will not handle the SIGINT signal.
OptionalsigintThe message to display when the SIGINT signal (CTRL+C) is received.
If not provided, a default message will be used.
This option is only used if sigintHandler is not set to false.
The printable title of the CLI.
OptionalusageUsage instructions for the CLI. Optional, but recommended. Use an array of strings for multiple lines to support indentation.
OptionalusageA label for the usage section. If not provided, it will default to "USAGE". This is used in the help message to indicate the usage section.
The options for clirk.