Files
himalaya/src/lib.rs
T
2026-01-21 22:12:30 +01:00

25 lines
535 B
Rust

pub mod account;
pub mod cli;
pub mod completion;
pub mod config;
pub mod email;
pub mod folder;
pub mod manual;
use std::path::PathBuf;
use shellexpand_utils::{canonicalize, expand};
#[doc(inline)]
pub use crate::email::{envelope, flag, message};
/// Parse the given [`str`] as [`PathBuf`].
///
/// The path is first shell expanded, then canonicalized (if
/// applicable).
fn dir_parser(path: &str) -> Result<PathBuf, String> {
expand::try_path(path)
.map(canonicalize::path)
.map_err(|err| err.to_string())
}