https://github.com/kantord/path_lookup-rs
Find all available executable commands in $PATH in Rust
https://github.com/kantord/path_lookup-rs
Last synced: 7 months ago
JSON representation
Find all available executable commands in $PATH in Rust
- Host: GitHub
- URL: https://github.com/kantord/path_lookup-rs
- Owner: kantord
- License: mit
- Created: 2024-01-29T10:18:58.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-01-29T11:56:52.000Z (over 1 year ago)
- Last Synced: 2025-01-10T14:53:46.413Z (9 months ago)
- Language: Rust
- Size: 6.84 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# path_lookup-rs
Find all available executable commands in ``$PATH`` in Rust.## Install
Add `path_lookup` to your `Cargo.toml`:
```bash
cargo add path_lookup
```## Usage
`iterate_executables()` returns an `Iterator`:
```rust
for command in iterate_executables() {
// ... etc ...
}
````get_executables()` returns a `HashSet`:
```rust
let all_commands: HashSet = get_executables();
```