Core LibraryunreleasedAPI Reference

Choose documentation 2

latest

Current version

latest
English

Unreleased LibTmux has not been released. Its API may change during development. This site's structure and URLs may change too.

method libtmux-perl latest

Server.new_window

new_window(session => Session|session_id, name => string?, command => arrayref?, shell_command => string?, cwd => bytes?, environment => hashref?).

Source and package
Qualified name
LibTmux::Server::new_window
Module
LibTmux
Declared in
Server
Package
LibTmux
Source
packages/core/lib/LibTmux/Server.pm
Other languages
Erlang PowerShell Julia Elixir Haskell Common Lisp PythonRubyLuaTypeScriptRustGoJavaC#C++SwiftKotlinScalaOCaml F# Clojure
sub new_window($self, %args)

Description#

Create a detached physical window in the selected session and return its captured LibTmux::Window. command, shell_command, cwd, and environment follow "new_session". The new link uses tmux's next available index. Performs I/O; "Creation" in LibTmux::X preserves known effects if subsequent acquisition fails.

my $window = $server->new_window(session => $session, name => 'logs', command => ['/bin/cat']);

Methods#

Parameters

tmux command#

The tmux commands behind new_window.

display-message (daemon identity or target preflight) list-clients (after accepted creation) list-panes -a server scope, cmd_list_panes_server (after accepted creation) list-sessions (after accepted creation) list-windows -a server scope, cmd_list_windows_exec (after accepted creation) new-window

tmux C API#

The C declarations in tmux that implement these commands.

In other ports#

Create a window

Esc

Type to search.

Reference previewOpen reference