Overview
Windows are the primary containers within a tmux session. Each session has one or more windows, and windows may be linked to multiple sessions. Windows are made up of one or more panes.new-window
Alias:neww
flag
Insert the new window at the next index after the specified target-window, moving windows up if necessary.
flag
Insert the new window at the next index before the specified target-window.
flag
Do not make the new window the current window.
flag
If the target window exists, destroy it before creating the new window.
flag
Print information about the new window after it has been created. Default format is
#{session_name}:#{window_index} but can be changed with -F.flag
Set synchronized-panes on for the new window.
string
Specify the working directory for the new window.
string
Set an environment variable for the new window in the form
VARIABLE=value. May be specified multiple times.string
Format for output when
-P is used.string
Name for the new window.
string
The target window position. If it doesn’t exist, the new window is created at the next free index.
string
Shell command to execute in the new window. If not specified, the default command is used.
kill-window
Alias:killw
flag
Kill all windows except the specified one.
string
The target window to destroy.
select-window
Alias:selectw
flag
Select the last (previously selected) window.
flag
Select the next window.
flag
Select the previous window.
flag
If the window is already the current window, select the last window.
string
The target window to select.
list-windows
Alias:lsw
flag
List all windows across all sessions.
flag
Reverse the sort order.
string
Specify the format of each line.
string
Only show windows for which the filter is true.
string
Specify sort order:
index, name, creation (time), or activity (time).string
List windows in the target session.
rename-window
Alias:renamew
new-name.
string
The target window to rename.
string
required
The new name for the window.
move-window
Alias:movew
flag
Move the window to the next index after dst-window.
flag
Move the window to the next index before dst-window.
flag
Do not make the moved window the current window.
flag
If dst-window exists, destroy it before moving or linking.
flag
Renumber windows in the session in sequential order.
string
The source window to move.
string
The destination window position.
link-window
Alias:linkw
flag
Link the window at the next index after dst-window.
flag
Link the window at the next index before dst-window.
flag
Do not make the linked window the current window.
flag
If dst-window exists, destroy it before linking.
string
The source window to link.
string
The destination window position.
unlink-window
Alias:unlinkw
flag
Kill the window if it is only present in one session.
string
The target window to unlink.
swap-window
Alias:swapw
flag
Do not make the swapped window the current window.
string
The source window.
string
The destination window.
rotate-window
Alias:rotatew
flag
Rotate downward (the last pane becomes the first).
flag
Rotate upward (the first pane becomes the last).
flag
Keep the window zoomed if it was zoomed.
string
The target window.
respawn-window
Alias:respawnw
string
Specify the working directory for the command.
string
Set an environment variable in the form
VARIABLE=value. May be specified multiple times.flag
Kill the existing command if it is still running.
string
The target window to respawn.
string
Shell command to execute. If not specified, the command used when the window was created is reused.
find-window
Alias:findw
match-string.
flag
Ignore case when matching.
flag
Match only visible window contents.
flag
Match only window names.
flag
Match match-string as a regular expression.
flag
Match only window titles.
flag
Zoom the pane.
string
The target pane for displaying results.
string
required
The string or pattern to search for.
last-window
Alias:last
string
The target session.
next-window
Alias:next
flag
Move to the next window with an alert (bell, activity, or silence).
string
The target session.
previous-window
Alias:prev
flag
Move to the previous window with an alert.
string
The target session.