CmdPlus class
CmdPlus is a class that provides a simple methods to run processes on the command line. It is a wrapper around the Process class, making it easier to log errors and process results with package:mason_logger.
Constructors
- CmdPlus({Logger? logger, ProcessManager? manager})
- CmdPlus is a class that provides a simple methods to run processes on the command line. It is a wrapper around the Process class, making it easier to log errors and process results with package:mason_logger.
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- logger → Logger
-
The logger to use to log errors and process results.
final
- manager ↔ ProcessManager?
-
The manager for the process.
getter/setter pair
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
close(
) → Future< void> - Frees up resources associated with this class.
-
copyDirectory(
{required Directory from, required Directory to, List< DirectoryFilter> filters = const [], bool enableLogging = true}) → Future<void> - {@macro cmd_plus}
-
copyFile(
{required File from, required File to, List< FileFilter> filters = const [], bool enableLogging = true, bool deleteFrom = false, bool deleteTo = false}) → void - {@template copy_file} CmdPlus is a class that provides a simple methods to run processes on the command line. It is a wrapper around the Process class, making it easier to log errors and process results with package:mason_logger.
-
deleteEmptyDirectories(
{required Directory directory, bool enableLogging = true}) → Future< void> - {@macro cmd_plus}
-
filterDirectory(
{required Directory directory, List< DirectoryFilter> filters = const [], bool enableLogging = true}) → Future<void> - {@macro cmd_plus}
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
run(
String cmd, List< String> args, {bool throwOnError = true, bool runInShell = true, bool includeParentEnvironment = true, String? workingDirectory, Map<String, String> ? environment, CmdPlusMode mode = const CmdPlusMode.normal()}) → Future<CmdPlusResult> - {@macro cmd_plus}
-
start(
String cmd, List< String> args, {bool throwOnError = true, bool runInShell = true, bool includeParentEnvironment = true, String? workingDirectory, Map<String, String> ? environment, CmdPlusMode mode = const CmdPlusMode.normal()}) → Future<CmdPlusResult> - {@macro cmd_plus}
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited