Crates.io | showfile |
lib.rs | showfile |
version | 0.1.1 |
source | src |
created_at | 2024-01-06 21:21:14.174436 |
updated_at | 2024-01-06 21:53:04.941354 |
description | Show files in the local file manager |
homepage | https://github.com/jf2048/showfile |
repository | https://github.com/jf2048/showfile.git |
max_upload_size | |
id | 1091229 |
size | 18,257 |
A simple Rust crate to show the location of a file in the local file manager (Explorer, Finder, etc.). Supported platforms are Windows, macOS, Linux.
showfile::show_path_in_file_manager("C:\\Users\\Alice\\hello.txt");
showfile::show_path_in_file_manager("/Users/Bob/hello.txt");
showfile::show_uri_in_file_manager("file:///home/charlie/hello.txt");
On Linux, D-Bus is used to invoke the file manager. The D-Bus crate in use can be selected with one of these flags:
One of these flags must be specified to build the project. These flags do nothing on Windows and macOS. If only targeting those platforms, it can be left at the default.
This crate is a simple wrapper around these system functions: