2 releases
0.1.1 | Jan 9, 2020 |
---|---|
0.1.0 | Jan 9, 2020 |
#28 in #folders
10KB
220 lines
picker
A cross-platform picker for access files and folders
Installation
Add picker
as a dependency in your Cargo.toml
:
[dependencies]
picker = "0.1.0"
Example
Pick a single file:
use picker::FileOpenPicker;
fn main() {
if let Ok(result) = FileOpenPicker::new()
.file_type_filter(&["zip", "dmg"])
.file_type_filter(&["png", "jpg"])
.pick_single_file()
{
if let Some(path) = result {
println!("Path is {}.", path);
}
}
}
Supported Platform
- macOS
- Windows
- Linux
Dependencies
~0.2–2.1MB
~40K SLoC