libtmux Reference MCP Search
On this page

command.CommandChain.new

View as Markdown

Module
command
Declared in
CommandChain
Package
libtmux
Source
crates/libtmux/src/command.rs
new ( command : Command ) Self
method [source]
method [source]
new

Start a chain from its first command.

Taking the first command here keeps a chain non-empty by construction: an empty argv would make tmux act as a client rather than run anything.

Examples

use libtmux::{Command, CommandChain};

let chain = CommandChain::new(Command::new("list-sessions"));
assert_eq!(chain.command_count(), 1);

0 declared, 0 inherited

Esc

Type to search.