Merge "Refresh Android.bp, cargo2android.json, TEST_MAPPING." am: 4be8607c62 am: 2e531088a9 am: 12248a1cda am: cdcdcf6d7e

Original change: https://android-review.googlesource.com/c/platform/external/rust/crates/which/+/1912836

Change-Id: I64ec07f6c8f507ef44616409a7f8e2532f6cc672
tree: 2ea0e76815a667dd8445edec8840f25fd980fc12
  1. .github/
  2. src/
  3. tests/
  4. .cargo_vcs_info.json
  5. .gitignore
  6. Android.bp
  7. Cargo.toml
  8. Cargo.toml.orig
  9. cargo2android.json
  10. LICENSE.txt
  11. METADATA
  12. MODULE_LICENSE_MIT
  13. OWNERS
  14. README.md
  15. TEST_MAPPING
README.md

Build Status

which

A Rust equivalent of Unix command “which”. Locate installed executable in cross platforms.

Support platforms

  • Linux
  • Windows
  • macOS

Example

To find which rustc exectable binary is using.

use which::which;

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

Documentation

The documentation is available online.