pub struct TmuxSession {
pub name: String,
/* private fields */
}Expand description
A fully-resolved tmux session ready to execute or inspect.
Fields§
§name: StringThe resolved session name (e.g. paw-myproject or paw-myproject-2).
Implementations§
Source§impl TmuxSession
impl TmuxSession
Sourcepub fn execute(&self) -> Result<(), PawError>
pub fn execute(&self) -> Result<(), PawError>
Execute all accumulated tmux commands against the live tmux server.
Soft commands (the border affordances) that fail produce a stderr warning naming the failed invocation and do not abort the build; any other command failure propagates as an error.
Sourcepub fn command_strings(&self) -> Vec<String>
pub fn command_strings(&self) -> Vec<String>
Return all commands as human-readable strings (for dry-run / testing).
Sourcepub fn pipe_pane(&mut self, pane_target: &str, log_path: &Path) -> &mut Self
pub fn pipe_pane(&mut self, pane_target: &str, log_path: &Path) -> &mut Self
Queue a pipe-pane command to capture pane output to a log file.
Appends tmux pipe-pane -o -t <pane_target> "cat >> <log_path>" to the
command queue. Should be called after the pane has been created.
Sourcepub fn reapply_tiled_layout(&mut self, session_name: &str) -> &mut Self
pub fn reapply_tiled_layout(&mut self, session_name: &str) -> &mut Self
Queue a command to reapply the tiled layout after any resize operation.
This ensures that the layout remains consistent even when tmux windows are resized from unattached clients. Should be called after any operation that might affect window dimensions.
Sourcepub fn apply_dashboard_layout(&mut self, session_name: &str) -> &mut Self
pub fn apply_dashboard_layout(&mut self, session_name: &str) -> &mut Self
Queue a command to apply the main-horizontal layout for dashboard sessions.
This layout puts the dashboard pane in a full-width row at the top, with worktree panes tiled below. Should be used when a dashboard pane is present (pane 0) and worktree panes follow.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for TmuxSession
impl RefUnwindSafe for TmuxSession
impl Send for TmuxSession
impl Sync for TmuxSession
impl Unpin for TmuxSession
impl UnsafeUnpin for TmuxSession
impl UnwindSafe for TmuxSession
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
impl<A, B, T> HttpServerConnExec<A, B> for Twhere
B: Body,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more