Represents the result of executing a command.
Output is streamed through sinks during execution rather than accumulated here.
Use OutputCollector to capture output when needed for testing.
Fields
command- The command string that was executedexit_code- The exit code (0 for success, non-zero for failure)error- Error type if command failed (:command_not_found,:timeout, etc.)
Summary
Types
@type error_type() :: :command_not_found | :command_failed | :timeout | term()
@type t() :: %Bash.CommandResult{ command: String.t(), error: error_type() | nil, exit_code: non_neg_integer() | nil }