pub fn dispatch(cmd: &Cmd, cwd: &Path) -> Result<i32>Expand description
Dispatch a parsed Cmd against cwd and return the per-
command exit code.
cwd is a parameter rather than read from
std::env::current_dir so callers (the binary, integration
tests, embedders) drive the dispatch deterministically. The
binary’s main reads cwd from the environment once and passes
it here.
§Errors
Returns a miette::Report on workspace-load, target-
resolution, or scheduler failure. The binary maps any report
to EXIT_INTERNAL_OR_CONFIG_ERROR.