Skip to main content

resolve_binary

Function resolve_binary 

Source
pub fn resolve_binary(
    name: &str,
    env_override: Option<&str>,
) -> Result<PathBuf, RunnerError>
Expand description

Resolve a binary path by name, optionally using an environment variable override

Resolution order:

  1. If env_override is Some, use that value as the path
  2. Otherwise, search PATH using which

§Errors

Returns RunnerError if the binary cannot be found.