Skip to main content

which_path

Function which_path 

Source
pub fn which_path(program: &str) -> Option<PathBuf>
Expand description

Absolute path of program if discoverable — first on PATH, then as a fallback in Cargo’s own bin dir ($CARGO_HOME/bin, e.g. C:\Users\<user>\.cargo\bin), which rustup tools live in but isn’t on PATH in every shell. Returns None when not found anywhere.