Expand description
Path utilities
Provides path canonicalization and validation helpers for file/directory pickers.
§Example
ⓘ
use ccf_gpui_widgets::utils::path::{parse_path, expand_tilde};
// Parse and canonicalize a path
let info = parse_path("~/Documents/output.txt");
if info.fully_exists() {
println!("File exists at: {}", info.full_path_string());
} else {
println!("Existing portion: {:?}", info.existing_canonical);
println!("Non-existing suffix: {:?}", info.non_existing_suffix);
}Structs§
- Path
Info - Result of parsing and canonicalizing a user-provided path
Functions§
- expand_
tilde - Expand tilde (~) to home directory
- parse_
path - Parse and canonicalize a user-provided path (which may be relative or non-canonical)