gecko-dev/third_party/rust/which
Nathan Froyd b93bf873ba Bug 1502964 - part 2 - update winapi to froydnj/winapi-rs#aarch64; r=ted.mielczarek 2018-11-02 10:56:08 -04:00
..
src
.cargo-checksum.json Bug 1502964 - part 2 - update winapi to froydnj/winapi-rs#aarch64; r=ted.mielczarek 2018-11-02 10:56:08 -04:00
Cargo.toml Bug 1412486: Revendor rust dependencies. r=me 2017-10-31 23:32:11 +01:00
LICENSE.txt
README.md Bug 1412486: Revendor rust dependencies. r=me 2017-10-31 23:32:11 +01:00

README.md

Build Status

which

A Rust equivalent of Unix command "which". Locate installed execuable in cross platforms.

Support platforms

  • Linux
  • Windows
  • macOS

Example

To find which rustc exectable binary is using. Locate installed execuable in cross platforms.

use which::which;

let result = which::which("rustc").unwrap();
assert_eq!(result, PathBuf::from("/usr/bin/rustc"));

Documentation

The documentation is available online.