CommandHelper class

Handles styled console output (errors, success, warnings) and CLI help/version.

This class centralizes formatting and exit behavior so the CLI stays consistent and easy to maintain. Error/success methods may exit the process.

Constructors

CommandHelper()

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

error(String message) → void
Prints a red error message and exits with code 1.
help() → void
Prints CLI usage information and exits.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
success(String message, {bool shouldExit = true}) → void
Prints a green success message.
toString() String
A string representation of this object.
inherited
version() Future<void>
Prints the package version from pubspec.yaml and exits.
warning(String message) → void
Prints a yellow warning message without exiting.

Operators

operator ==(Object other) bool
The equality operator.
inherited