better_command_runner library
Classes
-
BetterCommand<
O extends OptionDefinition, T> -
An extension of
Commandwith additional features. -
BetterCommandRunner<
O extends OptionDefinition, T> -
An extension of
CommandRunnerwith additional features. - BetterCommandRunnerAnalyticsEvents
- Constants for the command runner analytics events.
- BetterCommandRunnerFlags
- Constants for the command runner flags.
- MessageOutput
- A proxy for user-provided functions for passing specific log messages.
Enums
- CommandRunnerLogLevel
- An enum for the command runner log levels.
- CompletionTool
-
StandardGlobalOption<
V extends Object>
Typedefs
- CompletionScript = ({String script, CompletionTool tool})
- OnAnalyticsEvent = void Function(String event)
- A function type for tracking events.
-
OnBeforeRunCommand
= Future<
void> Function(BetterCommandRunner<OptionDefinition, dynamic> runner) - A function type for executing code before running a command.
- SetLogLevel = void Function({String? commandName, required CommandRunnerLogLevel parsedLogLevel})
-
A function type for setting the log level.
The
logLevelis the log level to set. ThecommandNameis the name of the command if custom rules for log levels are needed.
Exceptions / Errors
- ExitException
- An exception that can be thrown to exit the command with a specific exit code.