pub struct XdgPather { /* private fields */ }Expand description
XDG-compliant path resolver.
Reads standard environment variables (HOME, XDG_DATA_HOME, etc.)
and the dodot-specific DOTFILES_ROOT. All paths can also be set
explicitly via the builder for testing.
Implementations§
Trait Implementations§
Source§impl Pather for XdgPather
impl Pather for XdgPather
Source§fn dotfiles_root(&self) -> &Path
fn dotfiles_root(&self) -> &Path
Root of the dotfiles repository.
Source§fn config_dir(&self) -> &Path
fn config_dir(&self) -> &Path
XDG config directory for dodot (e.g.
~/.config/dodot).Source§fn xdg_config_home(&self) -> &Path
fn xdg_config_home(&self) -> &Path
XDG config home (e.g.
~/.config). Used by symlink handler
for subdirectory target mapping.Source§fn pack_data_dir(&self, pack: &str) -> PathBuf
fn pack_data_dir(&self, pack: &str) -> PathBuf
Data directory for a specific pack (e.g.
.../data/packs/{pack}).Source§fn handler_data_dir(&self, pack: &str, handler: &str) -> PathBuf
fn handler_data_dir(&self, pack: &str, handler: &str) -> PathBuf
Data directory for a specific handler within a pack
(e.g.
.../data/packs/{pack}/{handler}).Source§fn init_script_path(&self) -> PathBuf
fn init_script_path(&self) -> PathBuf
Path to the generated shell init script.
Auto Trait Implementations§
impl Freeze for XdgPather
impl RefUnwindSafe for XdgPather
impl Send for XdgPather
impl Sync for XdgPather
impl Unpin for XdgPather
impl UnsafeUnpin for XdgPather
impl UnwindSafe for XdgPather
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more