pub struct SessionEnvironment {
pub original_cwd: PathBuf,
pub project_root: PathBuf,
pub is_git_repo: bool,
pub git_branch: Option<String>,
pub platform: String,
pub shell: String,
pub is_interactive: bool,
pub terminal_width: u16,
}Expand description
Resolved session environment.
Fields§
§original_cwd: PathBufOriginal working directory at startup.
project_root: PathBufDetected project root (git root or cwd).
is_git_repo: boolWhether we’re inside a git repository.
git_branch: Option<String>Current git branch (if in a repo).
platform: StringPlatform identifier.
shell: StringDefault shell.
is_interactive: boolWhether the session is interactive (has a TTY).
terminal_width: u16Terminal width in columns.
Implementations§
Trait Implementations§
Source§impl Clone for SessionEnvironment
impl Clone for SessionEnvironment
Source§fn clone(&self) -> SessionEnvironment
fn clone(&self) -> SessionEnvironment
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for SessionEnvironment
impl RefUnwindSafe for SessionEnvironment
impl Send for SessionEnvironment
impl Sync for SessionEnvironment
impl Unpin for SessionEnvironment
impl UnsafeUnpin for SessionEnvironment
impl UnwindSafe for SessionEnvironment
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