Session.cmd
Execute tmux subcommand within session context.
Source and package
- Qualified name
-
libtmux.Session .cmd - Module
- libtmux
- Declared in
- Session
- Package
- libtmux
- Source
- src/libtmux/session.py
- Other languages
- PowerShell Julia Ruby Lua TypeScriptRustGo Java C# C++ Swift Kotlin Scala F#
-
Description#
Automatically binds target by adding
-tfor object's session ID to the command. Passtargetto keyword arguments to override.Examples#
>>> session.cmd('new-window', '-P').stdout[0]'libtmux...:....0'From raw output to an enriched
Windowobject:>>> Window.from_window_id(window_id=session.cmd(... 'new-window', '-P', '-F#{window_id}').stdout[0], server=session.server)Window(@... ...:..., Session($1 libtmux_...))In other ports Run a tmux command addressed at a session
- PowerShell No source-verified PowerShell equivalent is recorded for this operation.
- Julia No source-verified Julia equivalent is recorded for this operation.
- Ruby No source-verified Ruby equivalent is recorded for this operation.
- Lua No source-verified Lua equivalent is recorded for this operation.
- TypeScript
- Rust
- Go
- Java no equivalent on
Session - C# no equivalent on
Session - C++ no equivalent on
Session - Swift no equivalent on
Session - Kotlin No source-verified Kotlin equivalent is recorded for this operation.
- Scala No source-verified Scala equivalent is recorded for this operation.
- F# No source-verified F# equivalent is recorded for this operation.
- PowerShell