Core Library0.xAPI Reference

Choose documentation 3

latest

Current version

latest
English

Early release libtmux is released, and its APIs may still change between releases. This site's structure and URLs may change too.

method libtmux-java latest

Server.cmd

Runs one tmux command against this server.

Source and package
Qualified name
io.github.libtmux.Server.cmd
Package
io.github.libtmux
Declared in
Server
Distribution
io.github.libtmux:libtmux
Source
libtmux/src/main/java/io/github/libtmux/Server.java
Other languages
Perlmethod Erlangfunction PowerShell Julia Elixirfunction Haskell Common Lisp PythonRubyLuaTypeScriptRustGo C# C++ Swift Kotlin Scala OCaml F# Clojure

Description#

A command this release of tmux mishandles is refused with UnsupportedFeatureException before it is sent. Nested tmux command strings (if-shell, run-shell -C, hooks, brace blocks, source-file) are not checked; do not nest a command this library refuses.

Parameters
  • argv (String) # – the tmux command and its arguments, each already a separate element for cmd(argv) [overload 1]

  • argv (List<String>) # for cmd(argv) [overload 2]; cmd(argv, timeout)

  • timeout (Duration) # for cmd(argv, timeout)

Returns

the result, in which a nonzero exit is data rather than a failure for cmd(argv) [overload 1]

In other ports#

Run a tmux command this port does not model

Equivalents of Run a tmux command this port does not model in other languages
Language Equivalent
Python libtmux.Server.cmd
Ruby LibTmux::Server#run
Lua libtmux.Server:command
Erlang tmux_server:command/3 Executes an explicit command value with bounded output and separate outcome and cleanup evidence.
Elixir LibTmux.Server.run/3 Runs one trusted Command without attaching a client and returns bounded output with exit evidence.
Haskell No public Haskell equivalent is implemented; the current modules expose scalar values and version parsing.
TypeScript server.Server.cmd
Rust server.Server.cmd
Go tmux.Server.Cmd
C# no equivalent on Server
C++ no equivalent on Server
Swift no equivalent on Server
OCaml No direct public OCaml equivalent is recorded for this operation.
Perl LibTmux::Server::cmd Checked literal argument vector; no shell wrapper or implicit tmux command list.

No equivalent is recorded in PowerShell, Julia, Common Lisp, Clojure, Kotlin, Scala or F#.

Esc

Type to search.

Reference previewOpen reference