pub struct Context<'a> {
pub command: &'a str,
pub cwd: Option<&'a str>,
pub root: Option<&'a str>,
pub session_id: Option<&'a str>,
pub harness: &'a str,
pub level: &'a str,
}Expand description
Everything about the invocation that is not the verdict. Borrowed rather than owned so building one costs nothing on the path where the mode discards it.
Fields§
§command: &'a str§cwd: Option<&'a str>§root: Option<&'a str>§session_id: Option<&'a str>§harness: &'a strThe harness whose hook envelope was parsed (claude, codex, …), or cli.
level: &'a strThe auto-approve ceiling in force, as its level name.
Auto Trait Implementations§
impl<'a> Freeze for Context<'a>
impl<'a> RefUnwindSafe for Context<'a>
impl<'a> Send for Context<'a>
impl<'a> Sync for Context<'a>
impl<'a> Unpin for Context<'a>
impl<'a> UnsafeUnpin for Context<'a>
impl<'a> UnwindSafe for Context<'a>
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