pub struct WorktreeGuard {
pub path: PathBuf,
pub branch: String,
pub base_hash: String,
/* private fields */
}Expand description
A live per-run worktree. Created by create_worktree and cleaned up when
dropped (synchronous, so it works inside both regular code and Drop impls).
Moving it into the ACP stream generator ensures cleanup on stream completion
or on early client disconnect.
Fields§
§path: PathBufAbsolute path to the worktree directory.
branch: Stringryu/run-<id> branch created with the worktree.
base_hash: StringThe commit SHA from which this worktree was forked (the base for diff).
Trait Implementations§
Source§impl Drop for WorktreeGuard
impl Drop for WorktreeGuard
Auto Trait Implementations§
impl Freeze for WorktreeGuard
impl RefUnwindSafe for WorktreeGuard
impl Send for WorktreeGuard
impl Sync for WorktreeGuard
impl Unpin for WorktreeGuard
impl UnsafeUnpin for WorktreeGuard
impl UnwindSafe for WorktreeGuard
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