5 releases
| 0.2.0 | Dec 26, 2024 |
|---|---|
| 0.1.3 | Dec 26, 2024 |
| 0.1.2 | May 6, 2022 |
| 0.1.1 | Aug 3, 2018 |
| 0.1.0 | Aug 2, 2018 |
#1063 in Filesystem
54,281 downloads per month
Used in 24 crates
(19 directly)
8KB
93 lines
filepath
filepath contains an extension trait for std::fs::File providing a path method.
filepath
Get the filesystem path of a file.
A simple extension trait for File that provides a single method path, which returns the path of a file.
Note: Not every file has a path. The path might be wrong for example after moving a file.
OS support: Linux, Mac, Windows and iOS
use std::fs::File;
use filepath::FilePath;
let mut file = File::create("foo.txt").unwrap();
println!("{:?}", file.path());
Dependencies
~0–36MB
~458K SLoC