pub struct AppRoot(PathBuf);Expand description
The directory holding config.toml and profiles/.
Tuple Fields§
§0: PathBufImplementations§
Source§impl AppRoot
impl AppRoot
Sourcepub fn from_path(path: PathBuf) -> AppRoot
pub fn from_path(path: PathBuf) -> AppRoot
A root at an explicit path. Tests use this instead of changing the process environment.
Sourcepub fn resolve() -> Result<AppRoot>
pub fn resolve() -> Result<AppRoot>
AGENT_PROFILE_HOME when set, otherwise <home>/.agent-profile. Never creates anything.
fn resolve_from( home_override: Option<OsString>, home_dir: Option<PathBuf>, ) -> Result<AppRoot>
pub fn path(&self) -> &Path
pub fn config_path(&self) -> PathBuf
pub fn profiles_dir(&self) -> PathBuf
fn lock_path(&self) -> PathBuf
Trait Implementations§
impl Eq for AppRoot
impl StructuralPartialEq for AppRoot
Auto Trait Implementations§
impl Freeze for AppRoot
impl RefUnwindSafe for AppRoot
impl Send for AppRoot
impl Sync for AppRoot
impl Unpin for AppRoot
impl UnsafeUnpin for AppRoot
impl UnwindSafe for AppRoot
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.