Annotation of src/usr.bin/tmux/tmux.1, Revision 1.97
1.97 ! nicm 1: .\" $OpenBSD: tmux.1,v 1.96 2009/10/06 07:09:00 nicm Exp $
1.1 nicm 2: .\"
3: .\" Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net>
4: .\"
5: .\" Permission to use, copy, modify, and distribute this software for any
6: .\" purpose with or without fee is hereby granted, provided that the above
7: .\" copyright notice and this permission notice appear in all copies.
8: .\"
9: .\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
10: .\" WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
11: .\" MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
12: .\" ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
13: .\" WHATSOEVER RESULTING FROM LOSS OF MIND, USE, DATA OR PROFITS, WHETHER
14: .\" IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING
15: .\" OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
16: .\"
1.97 ! nicm 17: .Dd $Mdocdate: October 6 2009 $
1.1 nicm 18: .Dt TMUX 1
19: .Os
20: .Sh NAME
21: .Nm tmux
1.6 jmc 22: .Nd terminal multiplexer
1.1 nicm 23: .Sh SYNOPSIS
24: .Nm tmux
25: .Bk -words
1.90 nicm 26: .Op Fl 28dlquv
1.91 nicm 27: .Op Fl c Ar shell-command
1.1 nicm 28: .Op Fl f Ar file
29: .Op Fl L Ar socket-name
30: .Op Fl S Ar socket-path
31: .Op Ar command Op Ar flags
32: .Ek
33: .Sh DESCRIPTION
34: .Nm
1.59 jmc 35: is a terminal multiplexer:
36: it enables a number of terminals to be created, accessed, and
37: controlled from a single screen.
1.67 jmc 38: .Nm
39: may be detached from a screen
40: and continue running in the background,
41: then later reattached.
1.1 nicm 42: .Pp
1.60 nicm 43: When
44: .Nm
45: is started it creates a new
46: .Em session
47: with a single
48: .Em window
49: and displays it on screen.
50: A status line at the bottom of the screen
51: shows information on the current session
52: and is used to enter interactive commands.
53: .Pp
54: A session is a single collection of
55: .Em pseudo terminals
56: under the management of
57: .Nm .
58: Each session has one or more
59: windows linked to it.
60: A window occupies the entire screen
61: and may be split into rectangular panes,
62: each of which is a separate pseudo terminal
63: (the
64: .Xr pty 4
65: manual page documents the technical details of pseudo terminals).
66: Any number of
67: .Nm
68: instances may connect to the same session,
69: and any number of windows may be present in the same session.
70: Once all sessions are killed,
71: .Nm
72: exits.
73: .Pp
1.64 nicm 74: Each session is persistent and will survive accidental disconnection
1.66 jmc 75: (such as
1.64 nicm 76: .Xr ssh 1
1.67 jmc 77: connection timeout) or intentional detaching (with the
1.64 nicm 78: .Ql C-b d
79: key strokes).
80: .Nm
81: may be reattached using:
82: .Pp
83: .Dl $ tmux attach
1.60 nicm 84: .Pp
1.64 nicm 85: In
86: .Nm ,
87: a session is displayed on screen by a
88: .Em client
89: and all sessions are managed by a single
90: .Em server .
91: The server and each client are separate processes which communicate through a
92: socket in
93: .Pa /tmp .
1.65 nicm 94: .Pp
1.1 nicm 95: The options are as follows:
96: .Bl -tag -width "XXXXXXXXXXXX"
97: .It Fl 2
98: Force
99: .Nm
100: to assume the terminal supports 256 colours.
101: .It Fl 8
102: Like
103: .Fl 2 ,
1.6 jmc 104: but indicates that the terminal supports 88 colours.
1.91 nicm 105: .It Fl c Ar shell-command
106: Execute
107: .Ar shell-command
108: using the default shell.
109: If necessary, the
110: .Nm
111: server will be started to retrieve the
112: .Ic default-shell
113: option.
1.1 nicm 114: .It Fl d
115: Force
116: .Nm
117: to assume the terminal supports default colours.
118: .It Fl f Ar file
119: Specify an alternative configuration file.
120: By default,
121: .Nm
1.26 nicm 122: loads the system configuration file from
123: .Pa /etc/tmux.conf ,
124: if present, then looks for a user configuration file at
1.1 nicm 125: .Pa ~/.tmux.conf .
126: The configuration file is a set of
127: .Nm
128: commands which are executed in sequence when the server is first started.
1.61 nicm 129: .Pp
130: If a command in the configuration file fails,
131: .Nm
132: will report an error and exit without executing further commands.
1.82 nicm 133: .It Fl l
134: Behave as a login shell.
135: This flag currently has no effect and is for compatibility with other shells
136: when using tmux as a login shell.
1.1 nicm 137: .It Fl L Ar socket-name
138: .Nm
139: stores the server socket in a directory under
140: .Pa /tmp ;
141: the default socket is named
142: .Em default .
143: This option allows a different socket name to be specified, allowing several
144: independent
145: .Nm
146: servers to be run.
147: Unlike
148: .Fl S
149: a full path is not necessary: the sockets are all created in the same
150: directory.
1.2 nicm 151: .Pp
152: If the socket is accidentally removed, the
1.6 jmc 153: .Dv SIGUSR1
1.2 nicm 154: signal may be sent to the
155: .Nm
156: server process to recreate it.
1.4 sobrado 157: .It Fl q
1.6 jmc 158: Prevent the server sending various informational messages, for example when
1.4 sobrado 159: window flags are altered.
1.1 nicm 160: .It Fl S Ar socket-path
161: Specify a full alternative path to the server socket.
162: If
163: .Fl S
164: is specified, the default socket directory is not used and any
165: .Fl L
166: flag is ignored.
167: .It Fl u
168: .Nm
1.14 nicm 169: attempts to guess if the terminal is likely to support UTF-8 by checking the
170: first of the
171: .Ev LC_ALL ,
172: .Ev LC_CTYPE
173: and
1.2 nicm 174: .Ev LANG
1.14 nicm 175: environment variables to be set for the string "UTF-8".
1.5 nicm 176: This is not always correct: the
1.2 nicm 177: .Fl u
178: flag explicitly informs
179: .Nm
1.6 jmc 180: that UTF-8 is supported.
1.33 nicm 181: .Pp
182: If the server is started from a client passed
183: .Fl u
184: or where UTF-8 is detected, the
185: .Ic utf8
186: and
187: .Ic status-utf8
188: options are enabled in the global window and session options respectively.
1.1 nicm 189: .It Fl v
190: Request verbose logging.
191: This option may be specified multiple times for increasing verbosity.
192: Log messages will be saved into
193: .Pa tmux-client-PID.log
194: and
195: .Pa tmux-server-PID.log
196: files in the current directory, where
197: .Em PID
1.6 jmc 198: is the PID of the server or client process.
1.1 nicm 199: .It Ar command Op Ar flags
200: This specifies one of a set of commands used to control
201: .Nm ,
1.6 jmc 202: as described in the following sections.
1.59 jmc 203: If no commands are specified, the
1.1 nicm 204: .Ic new-session
205: command is assumed.
1.57 jmc 206: .El
1.64 nicm 207: .Sh KEY BINDINGS
208: .Nm
209: may be controlled from an attached client by using a key combination of a
210: prefix key,
211: .Ql C-b
212: (Ctrl-b) by default, followed by a command key.
213: .Pp
214: Some of the default key bindings are:
215: .Pp
1.67 jmc 216: .Bl -tag -width Ds -offset indent -compact
1.64 nicm 217: .It c
1.65 nicm 218: Create a new window.
1.64 nicm 219: .It d
1.65 nicm 220: Detach the current client.
1.64 nicm 221: .It l
1.65 nicm 222: Move to the previously selected window.
1.64 nicm 223: .It n
1.65 nicm 224: Change to the next window.
1.64 nicm 225: .It p
1.65 nicm 226: Change to the previous window.
227: .It &
228: Kill the current window.
229: .It ,
230: Rename the current window.
1.64 nicm 231: .It \&?
1.65 nicm 232: List all key bindings.
1.64 nicm 233: .El
234: .Pp
235: A complete list may be obtained with the
236: .Ic list-keys
237: command (bound to
238: .Ql \&?
239: by default).
240: Key bindings may be changed with the
241: .Ic bind-key
242: and
243: .Ic unbind-key
244: commands.
1.57 jmc 245: .Sh COMMANDS
246: This section contains a list of the commands supported by
247: .Nm .
248: Most commands accept the optional
249: .Fl t
250: argument with one of
251: .Ar target-client ,
252: .Ar target-session
253: .Ar target-window ,
254: or
255: .Ar target-pane .
256: These specify the client, session, window or pane which a command should affect.
257: .Ar target-client
258: is the name of the
259: .Xr pty 4
260: file to which the client is connected, for example either of
261: .Pa /dev/ttyp1
262: or
263: .Pa ttyp1
264: for the client attached to
265: .Pa /dev/ttyp1 .
266: If no client is specified, the current client is chosen, if possible, or an
267: error is reported.
268: Clients may be listed with the
269: .Ic list-clients
270: command.
1.1 nicm 271: .Pp
1.57 jmc 272: .Ar target-session
273: is either the name of a session (as listed by the
274: .Ic list-sessions
275: command) or the name of a client with the same syntax as
276: .Ar target-client ,
277: in which case the session attached to the client is used.
278: When looking for the session name,
279: .Nm
280: initially searches for an exact match; if none is found, the session names
281: are checked for any for which
282: .Ar target-session
283: is a prefix or for which it matches as an
284: .Xr fnmatch 3
285: pattern.
286: If a single match is found, it is used as the target session; multiple matches
287: produce an error.
288: If a session is omitted, the current session is used if available; if no
289: current session is available, the most recently created is chosen.
1.1 nicm 290: .Pp
1.57 jmc 291: .Ar target-window
292: specifies a window in the form
293: .Em session Ns \&: Ns Em window .
294: .Em session
295: follows the same rules as for
296: .Ar target-session ,
297: and
298: .Em window
299: is looked for in order: as a window index, for example mysession:1; as an exact
300: window name, such as mysession:mywindow; then as an
301: .Xr fnmatch 3
302: pattern or the start of a window name, such as mysession:mywin* or
303: mysession:mywin.
304: An empty window name specifies the next unused index if appropriate (for
305: example the
306: .Ic new-window
307: and
308: .Ic link-window
309: commands)
310: otherwise the current window in
311: .Em session
312: is chosen.
313: When the argument does not contain a colon,
314: .Nm
315: first attempts to parse it as window; if that fails, an attempt is made to
316: match a session.
1.1 nicm 317: .Pp
1.57 jmc 318: .Ar target-pane
319: takes a similar form to
320: .Ar target-window
321: but with the optional addition of a period followed by a pane index, for
322: example: mysession:mywindow.1.
323: If the pane index is omitted, the currently active pane in the specified
324: window is used.
325: If neither a colon nor period appears,
1.13 nicm 326: .Nm
1.57 jmc 327: first attempts to use the argument as a pane index; if that fails, it is looked
328: up as for
329: .Ar target-window .
1.15 jmc 330: .Pp
1.57 jmc 331: Multiple commands may be specified together as part of a
332: .Em command sequence .
333: Each command should be separated by spaces and a semicolon;
334: commands are executed sequentially from left to right.
335: A literal semicolon may be included by escaping it with a backslash (for
336: example, when specifying a command sequence to
337: .Ic bind-key ) .
1.13 nicm 338: .Pp
1.57 jmc 339: Examples include:
1.13 nicm 340: .Bd -literal -offset indent
1.57 jmc 341: refresh-client -t/dev/ttyp2
342:
343: rename-session -tfirst newname
344:
345: set-window-option -t:0 monitor-activity on
346:
347: new-window ; split-window -d
1.13 nicm 348: .Ed
1.57 jmc 349: .Sh CLIENTS AND SESSIONS
350: The following commands are available:
351: .Bl -tag -width Ds
352: .It Xo Ic attach-session
353: .Op Fl d
354: .Op Fl t Ar target-session
355: .Xc
356: .D1 (alias: Ic attach )
357: If run from outside
358: .Nm ,
359: create a new client in the current terminal and attach it to
360: .Ar target-session .
361: If used from inside, switch the current client.
362: If
363: .Fl d
364: is specified, any other clients attached to the session are detached.
1.13 nicm 365: .Pp
1.57 jmc 366: If no server is started,
367: .Ic attach-session
368: will attempt to start it; this will fail unless sessions are created in the
369: configuration file.
370: .It Ic detach-client Op Fl t Ar target-client
371: .D1 (alias: Ic detach )
372: Detach the current client if bound to a key, or the specified client with
373: .Fl t .
374: .It Ic has-session Op Fl t Ar target-session
375: .D1 (alias: Ic has )
376: Report an error and exit with 1 if the specified session does not exist.
377: If it does exist, exit with 0.
378: .It Ic kill-server
379: Kill the
1.1 nicm 380: .Nm
1.57 jmc 381: server and clients and destroy all sessions.
382: .It Ic kill-session Op Fl t Ar target-session
383: Destroy the given session, closing any windows linked to it and no other
384: sessions, and detaching all clients attached to it.
385: .It Ic list-clients
386: .D1 (alias: Ic lsc )
387: List all clients attached to the server.
388: .It Ic list-commands
389: .D1 (alias: Ic lscm )
390: List the syntax of all commands supported by
391: .Nm .
392: .It Ic list-sessions
393: .D1 (alias: Ic ls )
394: List all sessions managed by the server.
1.92 nicm 395: .It Xo Ic lock-client
396: .Op Fl t Ar target-client
397: .Xc
398: Lock
399: .Ar target-client ,
400: see the
401: .Ic lock-server
402: command.
403: .It Xo Ic lock-session
404: .Op Fl t Ar target-session
405: .Xc
406: Lock all clients attached to
407: .Ar target-session .
1.57 jmc 408: .It Xo Ic new-session
409: .Op Fl d
410: .Op Fl n Ar window-name
411: .Op Fl s Ar session-name
412: .Op Ar command
413: .Xc
414: .D1 (alias: Ic new )
415: Create a new session with name
416: .Ar session-name .
417: The new session is attached to the current terminal unless
418: .Fl d
419: is given.
420: .Ar window-name
1.1 nicm 421: and
1.57 jmc 422: .Ar command
423: are the name of and command to execute in the initial window.
1.68 nicm 424: .Pp
425: If run from a terminal, any
426: .Xr termios 4
427: special characters are saved and used for new windows in the new session.
1.57 jmc 428: .It Ic refresh-client Op Fl t Ar target-client
429: .D1 (alias: Ic refresh )
430: Refresh the current client if bound to a key, or a single client if one is given
431: with
432: .Fl t .
433: .It Xo Ic rename-session
434: .Op Fl t Ar target-session
435: .Ar new-name
436: .Xc
437: .D1 (alias: Ic rename )
438: Rename the session to
439: .Ar new-name .
440: .It Ic source-file Ar path
441: .D1 (alias: Ic source )
442: Execute commands from
443: .Ar path .
444: .It Ic start-server
445: .D1 (alias: Ic start )
446: Start the
1.1 nicm 447: .Nm
1.57 jmc 448: server, if not already running, without creating any sessions.
449: .It Xo Ic suspend-client
450: .Op Fl c Ar target-client
451: .Xc
452: .D1 (alias: Ic suspendc )
453: Suspend a client by sending
454: .Dv SIGTSTP
455: (tty stop).
456: .It Xo Ic switch-client
457: .Op Fl c Ar target-client
458: .Op Fl t Ar target-session
459: .Xc
460: .D1 (alias: Ic switchc )
461: Switch the current session for client
462: .Ar target-client
463: to
464: .Ar target-session .
465: .El
466: .Sh WINDOWS AND PANES
1.1 nicm 467: A
468: .Nm
469: window may be in one of several modes.
470: The default permits direct access to the terminal attached to the window.
471: The others are:
472: .Bl -tag -width Ds
473: .It Em output mode
474: This is entered when a command which produces output, such as
475: .Ic list-keys ,
476: is executed from a key binding.
477: .It Em copy mode
478: This permits a section of a window or its history to be copied to a
479: .Em paste buffer
480: for later insertion into another window.
481: This mode is entered with the
482: .Ic copy-mode
483: command, bound to
484: .Ql [
485: by default.
486: .El
487: .Pp
1.6 jmc 488: The keys available depend on whether emacs or vi mode is selected
489: (see the
1.1 nicm 490: .Ic mode-keys
491: option).
492: The following keys are supported as appropriate for the mode:
493: .Bl -column "FunctionXXXXXXXXXXXX" "viXXXXXX" "emacs" -offset indent
494: .It Sy "Function" Ta Sy "vi" Ta Sy "emacs"
1.27 nicm 495: .It Li "Back to indentation" Ta "^" Ta "M-m"
1.1 nicm 496: .It Li "Clear selection" Ta "Escape" Ta "C-g"
497: .It Li "Copy selection" Ta "Enter" Ta "M-w"
498: .It Li "Cursor down" Ta "j" Ta "Down"
1.70 nicm 499: .It Li "Cursor left" Ta "h" Ta "Left"
500: .It Li "Cursor right" Ta "l" Ta "Right"
501: .It Li "Cursor up" Ta "k" Ta "Up"
1.71 nicm 502: .It Li "Delete entire line" Ta "d" Ta "C-u"
1.70 nicm 503: .It Li "Delete to end of line" Ta "D" Ta "C-k"
1.1 nicm 504: .It Li "End of line" Ta "$" Ta "C-e"
1.94 nicm 505: .It Li "Goto line" Ta ":" Ta "g"
1.1 nicm 506: .It Li "Next page" Ta "C-f" Ta "Page down"
507: .It Li "Next word" Ta "w" Ta "M-f"
1.70 nicm 508: .It Li "Paste buffer" Ta "p" Ta "C-y"
1.1 nicm 509: .It Li "Previous page" Ta "C-u" Ta "Page up"
510: .It Li "Previous word" Ta "b" Ta "M-b"
511: .It Li "Quit mode" Ta "q" Ta "Escape"
1.96 nicm 512: .It Li "Scroll down" Ta "C-Down" Ta "C-Down"
513: .It Li "Scroll up" Ta "C-Up" Ta "C-Up"
1.70 nicm 514: .It Li "Search again" Ta "n" Ta "n"
515: .It Li "Search backward" Ta "?" Ta "C-r"
516: .It Li "Search forward" Ta "/" Ta "C-s"
517: .It Li "Start of line" Ta "0" Ta "C-a"
1.1 nicm 518: .It Li "Start selection" Ta "Space" Ta "C-Space"
1.80 nicm 519: .It Li "Transpose chars" Ta "" Ta "C-t"
1.1 nicm 520: .El
521: .Pp
1.48 nicm 522: These key bindings are defined in a set of named tables:
523: .Em vi-edit
524: and
525: .Em emacs-edit
526: for keys used when line editing at the command prompt;
527: .Em vi-choice
528: and
529: .Em emacs-choice
530: for keys used when choosing from lists (such as produced by the
531: .Ic window-choose
532: command) or in output mode; and
533: .Em vi-copy
534: and
535: .Em emacs-copy
1.97 ! nicm 536: used in copy mode.
1.48 nicm 537: The tables may be viewed with the
538: .Ic list-keys
1.49 nicm 539: command and keys modified or removed with
540: .Ic bind-key
541: and
542: .Ic unbind-key .
1.48 nicm 543: .Pp
1.2 nicm 544: The paste buffer key pastes the first line from the top paste buffer on the
545: stack.
1.57 jmc 546: .Pp
547: The mode commands are as follows:
548: .Bl -tag -width Ds
549: .It Xo Ic copy-mode
550: .Op Fl u
1.72 nicm 551: .Op Fl t Ar target-pane
1.57 jmc 552: .Xc
553: Enter copy mode.
554: The
555: .Fl u
556: option scrolls one page up.
557: .El
1.18 nicm 558: .Pp
1.1 nicm 559: Each window displayed by
560: .Nm
561: may be split into one or more
562: .Em panes ;
563: each pane takes up a certain area of the display and is a separate terminal.
564: A window may be split into panes using the
565: .Ic split-window
566: command.
1.38 nicm 567: Windows may be split horizontally (with the
568: .Fl h
569: flag) or vertically.
570: Panes may be resized with the
571: .Ic resize-pane
1.1 nicm 572: command (bound to
1.38 nicm 573: .Ql C-up ,
574: .Ql C-down
575: .Ql C-left
576: and
577: .Ql C-right
1.1 nicm 578: by default), the current pane may be changed with the
579: .Ic up-pane
580: and
581: .Ic down-pane
582: commands and the
583: .Ic rotate-window
584: and
585: .Ic swap-pane
1.38 nicm 586: commands may be used to swap panes without changing their position.
587: Panes are numbered beginning from zero in the order they are created.
588: .Pp
589: A number of preset
590: .Em layouts
591: are available.
592: These may be selected with the
593: .Ic select-layout
594: command or cycled with
595: .Ic next-layout
596: (bound to
597: .Ql C-space
598: by default); once a layout is chosen, panes within it may be moved and resized as normal.
1.1 nicm 599: .Pp
600: The following layouts are supported:
601: .Bl -tag -width Ds
602: .It Ic even-horizontal
603: Panes are spread out evenly from left to right across the window.
604: .It Ic even-vertical
605: Panes are spread evenly from top to bottom.
1.2 nicm 606: .It Ic main-horizontal
607: A large (main) pane is shown at the top of the window and the remaining panes are
1.6 jmc 608: spread from left to right in the leftover space at the bottom.
1.2 nicm 609: Use the
610: .Em main-pane-height
611: window option to specify the height of the top pane.
1.1 nicm 612: .It Ic main-vertical
1.2 nicm 613: Similar to
614: .Ic main-horizontal
615: but the large pane is placed on the left and the others spread from top to
616: bottom along the right.
617: See the
618: .Em main-pane-width
619: window option.
1.1 nicm 620: .El
1.8 nicm 621: .Pp
1.57 jmc 622: Commands related to windows and panes are as follows:
623: .Bl -tag -width Ds
624: .It Xo Ic break-pane
625: .Op Fl d
626: .Op Fl t Ar target-pane
627: .Xc
628: .D1 (alias: Ic breakp )
629: Break
630: .Ar target-pane
631: off from its containing window to make it the only pane in a new window.
632: If
633: .Fl d
634: is given, the new window does not become the current window.
1.76 nicm 635: .It Xo
636: .Ic choose-client
637: .Op Fl t Ar target-window
638: .Op Ar template
639: .Xc
640: Put a window into client choice mode, allowing a client to be selected
641: interactively from a list.
642: After a client is chosen,
643: .Ql %%
644: is replaced by the client
645: .Xr pty 4
646: path in
647: .Ar template
648: and the result executed as a command.
649: If
650: .Ar template
651: is not given, "detach-client -t '%%'" is used.
1.57 jmc 652: This command works only from inside
653: .Nm .
1.76 nicm 654: .It Xo
655: .Ic choose-session
656: .Op Fl t Ar target-window
657: .Op Ar template
658: .Xc
659: Put a window into session choice mode, where a session may be selected
660: interactively from a list.
661: When one is chosen,
662: .Ql %%
663: is replaced by the session name in
664: .Ar template
665: and the result executed as a command.
666: If
667: .Ar template
668: is not given, "switch-client -t '%%'" is used.
669: This command works only from inside
670: .Nm .
671: .It Xo
672: .Ic choose-window
673: .Op Fl t Ar target-window
674: .Op Ar template
675: .Xc
676: Put a window into window choice mode, where a window may be chosen
677: interactively from a list.
678: After a window is selected,
679: .Ql %%
680: is replaced by the session name and window index in
681: .Ar template
682: and the result executed as a command.
683: If
684: .Ar template
685: is not given, "select-window -t '%%'" is used.
1.57 jmc 686: This command works only from inside
687: .Nm .
1.78 nicm 688: .It Ic display-panes Op Fl t Ar target-client
689: .D1 (alias: Ic displayp)
690: Display a visible indicator of each pane shown by
691: .Ar target-client .
692: See the
693: .Ic display-panes-time
694: and
695: .Ic display-panes-colour
696: session options.
1.84 nicm 697: While the indicator is on screen, a pane may be selected with the
698: .Ql 0
699: to
700: .Ql 9
701: keys.
1.57 jmc 702: .It Ic down-pane Op Fl t Ar target-pane
703: .D1 (alias: Ic downp )
704: Move down a pane.
705: .It Xo Ic find-window
706: .Op Fl t Ar target-window
707: .Ar match-string
708: .Xc
709: .D1 (alias: Ic findw )
710: Search for the
711: .Xr fnmatch 3
712: pattern
713: .Ar match-string
714: in window names, titles, and visible content (but not history).
715: If only one window is matched, it'll be automatically selected, otherwise a
716: choice list is shown.
717: This command only works from inside
1.1 nicm 718: .Nm .
1.57 jmc 719: .It Ic kill-pane Op Fl t Ar target-pane
720: .D1 (alias: Ic killp )
721: Destroy the given pane.
722: If no panes remain in the containing window, it is also destroyed.
723: .It Ic kill-window Op Fl t Ar target-window
724: .D1 (alias: Ic killw )
725: Kill the current window or the window at
726: .Ar target-window ,
1.1 nicm 727: removing it from any sessions to which it is linked.
1.56 jmc 728: .It Ic last-window Op Fl t Ar target-session
1.1 nicm 729: .D1 (alias: Ic last )
730: Select the last (previously selected) window.
731: If no
732: .Ar target-session
733: is specified, select the last window of the current session.
734: .It Xo Ic link-window
735: .Op Fl dk
736: .Op Fl s Ar src-window
737: .Op Fl t Ar dst-window
738: .Xc
739: .D1 (alias: Ic linkw )
740: Link the window at
741: .Ar src-window
742: to the specified
743: .Ar dst-window .
744: If
745: .Ar dst-window
746: is specified and no such window exists, the
747: .Ar src-window
748: is linked there.
749: If
750: .Fl k
751: is given and
752: .Ar dst-window
753: exists, it is killed, otherwise an error is generated.
754: If
755: .Fl d
756: is given, the newly linked window is not selected.
1.56 jmc 757: .It Ic list-windows Op Fl t Ar target-session
1.1 nicm 758: .D1 (alias: Ic lsw )
759: List windows in the current session or in
760: .Ar target-session .
761: .It Xo Ic move-window
762: .Op Fl d
763: .Op Fl s Ar src-window
764: .Op Fl t Ar dst-window
765: .Xc
766: .D1 (alias: Ic movew )
767: This is similar to
768: .Ic link-window ,
769: except the window at
770: .Ar src-window
771: is moved to
772: .Ar dst-window .
773: .It Xo Ic new-window
1.28 nicm 774: .Op Fl dk
1.1 nicm 775: .Op Fl n Ar window-name
776: .Op Fl t Ar target-window
777: .Op Ar command
778: .Xc
779: .D1 (alias: Ic neww )
780: Create a new window.
781: If
782: .Fl d
783: is given, the session does not make the new window the current window.
784: .Ar target-window
1.28 nicm 785: represents the window to be created; if the target already exists an error is
786: shown, unless the
787: .Fl k
788: flag is used, in which case it is destroyed.
1.1 nicm 789: .Ar command
790: is the command to execute.
791: If
792: .Ar command
793: is not specified, the default command is used.
794: .Pp
795: The
796: .Ev TERM
797: environment variable must be set to
798: .Dq screen
799: for all programs running
800: .Em inside
801: .Nm .
802: New windows will automatically have
803: .Dq TERM=screen
804: added to their environment, but care must be taken not to reset this in shell
805: start-up files.
1.56 jmc 806: .It Ic next-layout Op Fl t Ar target-window
1.1 nicm 807: .D1 (alias: Ic nextl )
808: Move a window to the next layout and rearrange the panes to fit.
809: .It Xo Ic next-window
1.9 nicm 810: .Op Fl a
1.1 nicm 811: .Op Fl t Ar target-session
812: .Xc
813: .D1 (alias: Ic next )
814: Move to the next window in the session.
1.9 nicm 815: If
1.12 jmc 816: .Fl a
1.9 nicm 817: is used, move to the next window with a bell, activity or content alert.
1.1 nicm 818: .It Xo Ic previous-window
1.9 nicm 819: .Op Fl a
1.1 nicm 820: .Op Fl t Ar target-session
821: .Xc
822: .D1 (alias: Ic prev )
823: Move to the previous window in the session.
1.9 nicm 824: With
825: .Fl a ,
826: move to the previous window with a bell, activity or content alert.
1.1 nicm 827: .It Xo Ic rename-window
828: .Op Fl t Ar target-window
829: .Ar new-name
830: .Xc
831: .D1 (alias: Ic renamew )
832: Rename the current window, or the window at
833: .Ar target-window
834: if specified, to
835: .Ar new-name .
836: .It Xo Ic resize-pane
1.39 jmc 837: .Op Fl DLRU
1.52 nicm 838: .Op Fl t Ar target-pane
1.1 nicm 839: .Op Ar adjustment
840: .Xc
841: .D1 (alias: Ic resizep )
1.57 jmc 842: Resize a pane, upward with
843: .Fl U
844: (the default), downward with
845: .Fl D ,
846: to the left with
847: .Fl L
848: and to the right with
849: .Fl R .
850: The
851: .Ar adjustment
852: is given in lines or cells (the default is 1).
853: .It Xo Ic respawn-window
854: .Op Fl k
855: .Op Fl t Ar target-window
856: .Op Ar command
857: .Xc
858: .D1 (alias: Ic respawnw )
859: Reactive a window in which the command has exited (see the
860: .Ic remain-on-exit
861: window option).
862: If
863: .Ar command
864: is not given, the command used when the window was created is executed.
865: The window must be already inactive, unless
866: .Fl k
867: is given, in which case any existing command is killed.
868: .It Xo Ic rotate-window
869: .Op Fl DU
870: .Op Fl t Ar target-window
871: .Xc
872: .D1 (alias: Ic rotatew )
873: Rotate the positions of the panes within a window, either upward (numerically
874: lower) with
875: .Fl U
876: or downward (numerically higher).
877: .It Xo Ic select-layout
878: .Op Fl t Ar target-window
879: .Op Ar layout-name
880: .Xc
881: .D1 (alias: selectl )
882: Choose a specific layout for a window.
883: If
884: .Ar layout-name
885: is not given, the last layout used (if any) is reapplied.
886: .It Ic select-pane Op Fl t Ar target-pane
887: .D1 (alias: Ic selectp )
888: Make pane
889: .Ar target-pane
890: the active pane in window
891: .Ar target-window .
892: .It Ic select-window Op Fl t Ar target-window
893: .D1 (alias: Ic selectw )
894: Select the window at
895: .Ar target-window .
896: .It Xo Ic split-window
897: .Op Fl dhv
898: .Oo Fl l
899: .Ar size |
900: .Fl p Ar percentage Oc
901: .Op Fl t Ar target-window
902: .Op Ar command
903: .Xc
904: .D1 (alias: splitw )
905: Creates a new pane by splitting the active pane:
906: .Fl h
907: does a horizontal split and
908: .Fl v
909: a vertical split; if neither is specified,
910: .Fl v
911: is assumed.
912: The
913: .Fl l
914: and
915: .Fl p
916: options specify the size of the new window in lines (for vertical split) or in
917: cells (for horizontal split), or as a percentage, respectively.
918: All other options have the same meaning as in the
919: .Ic new-window
920: command.
921: .It Xo Ic swap-pane
922: .Op Fl dDU
923: .Op Fl s Ar src-pane
924: .Op Fl t Ar dst-pane
925: .Xc
926: .D1 (alias: Ic swapp )
927: Swap two panes.
928: If
929: .Fl U
930: is used and no source pane is specified with
931: .Fl s ,
932: .Ar dst-pane
933: is swapped with the previous pane (before it numerically);
934: .Fl D
935: swaps with the next pane (after it numerically).
936: .It Xo Ic swap-window
937: .Op Fl d
938: .Op Fl s Ar src-window
939: .Op Fl t Ar dst-window
940: .Xc
941: .D1 (alias: Ic swapw )
942: This is similar to
943: .Ic link-window ,
944: except the source and destination windows are swapped.
945: It is an error if no window exists at
946: .Ar src-window .
947: .It Xo Ic unlink-window
1.1 nicm 948: .Op Fl k
949: .Op Fl t Ar target-window
950: .Xc
1.57 jmc 951: .D1 (alias: Ic unlinkw )
952: Unlink
953: .Ar target-window .
954: Unless
955: .Fl k
956: is given, a window may be unlinked only if it is linked to multiple sessions -
957: windows may not be linked to no sessions;
958: if
1.1 nicm 959: .Fl k
1.57 jmc 960: is specified and the window is linked to only one session, it is unlinked and
961: destroyed.
962: .It Ic up-pane Op Fl t Ar target-pane
963: .D1 (alias: Ic upp )
964: Move up a pane.
965: .El
966: .Sh KEY BINDINGS
1.93 nicm 967: .Nm
968: allows a command to be bound to most keys, with or without a prefix key.
969: When specifying keys, most represent themselves (for example
970: .Ql A
971: to
1.95 jmc 972: .Ql Z ) .
1.93 nicm 973: Ctrl keys may be prefixed with
974: .Ql C-
975: or
1.95 jmc 976: .Ql ^ ,
977: and Alt (meta) with
1.93 nicm 978: .Ql M- .
979: In addition, the following special key names are accepted:
980: .Em BSpace ,
981: .Em BTab ,
982: .Em DC
983: (Delete),
984: .Em End ,
985: .Em Enter ,
986: .Em Escape ,
987: .Em F1
988: to
989: .Em F20 ,
990: .Em Home ,
991: .Em IC
992: (Insert),
993: .Em NPage
994: (Page Up),
995: .Em PPage
996: (Page Down),
997: .Em Space ,
998: and
999: .Em Tab .
1000: Note that to bind the
1001: .Ql \&"
1002: or
1003: .Ql '
1004: keys, quotation marks are necessary, for example:
1005: .Bd -literal -offset indent
1006: bind-key '"' split-window
1007: bind-key "'" select-prompt
1008: .Ed
1009: .Pp
1.57 jmc 1010: Commands related to key bindings are as follows:
1011: .Bl -tag -width Ds
1012: .It Xo Ic bind-key
1013: .Op Fl cnr
1014: .Op Fl t Ar key-table
1015: .Ar key Ar command Op Ar arguments
1.1 nicm 1016: .Xc
1.57 jmc 1017: .D1 (alias: Ic bind )
1018: Bind key
1019: .Ar key
1020: to
1021: .Ar command .
1022: By default (without
1023: .Fl t )
1024: the primary key bindings are modified (those normally activated with the prefix
1025: key); in this case, if
1026: .Fl n
1027: is specified, it is not necessary to use the prefix key,
1028: .Ar command
1029: is bound to
1030: .Ar key
1031: alone.
1.1 nicm 1032: The
1.57 jmc 1033: .Fl r
1034: flag indicates this key may repeat, see the
1035: .Ic repeat-time
1036: option.
1037: .Pp
1038: If
1039: .Fl t
1040: is present,
1041: .Ar key
1042: is bound in
1043: .Ar key-table :
1044: the binding for command mode with
1045: .Fl c
1046: or for normal mode without.
1047: To view the default bindings and possible commands, see the
1048: .Ic list-keys
1049: command.
1050: .It Ic list-keys Op Fl t Ar key-table
1051: .D1 (alias: Ic lsk )
1052: List all key bindings.
1053: Without
1054: .Fl t
1055: the primary key bindings - those executed when preceded by the prefix key -
1056: are printed.
1057: Keys bound without the prefix key (see
1058: .Ic bind-key
1059: .Fl n )
1060: are enclosed in square brackets.
1061: .Pp
1062: With
1063: .Fl t ,
1064: the key bindings in
1065: .Ar key-table
1066: are listed; this may be one of:
1067: .Em vi-edit ,
1068: .Em emacs-edit ,
1069: .Em vi-choice ,
1070: .Em emacs-choice ,
1071: .Em vi-copy
1072: or
1073: .Em emacs-copy .
1074: .It Xo Ic send-keys
1.72 nicm 1075: .Op Fl t Ar target-pane
1.57 jmc 1076: .Ar key Ar ...
1.1 nicm 1077: .Xc
1.57 jmc 1078: .D1 (alias: Ic send )
1079: Send a key or keys to a window.
1080: Each argument
1081: .Ar key
1082: is the name of the key (such as
1083: .Ql C-a
1084: or
1085: .Ql npage
1086: ) to send; if the string is not recognised as a key, it is sent as a series of
1087: characters.
1088: All arguments are sent sequentially from first to last.
1.72 nicm 1089: .It Ic send-prefix Op Fl t Ar target-pane
1.57 jmc 1090: Send the prefix key to a window as if it was pressed.
1.89 nicm 1091: If multiple prefix keys are configured, only the first is sent.
1.57 jmc 1092: .It Xo Ic unbind-key
1093: .Op Fl cn
1094: .Op Fl t Ar key-table
1095: .Ar key
1.2 nicm 1096: .Xc
1.57 jmc 1097: .D1 (alias: Ic unbind )
1098: Unbind the command bound to
1099: .Ar key .
1100: Without
1101: .Fl t
1102: the primary key bindings are modified; in this case, if
1103: .Fl n
1104: is specified, the command bound to
1105: .Ar key
1106: without a prefix (if any) is removed.
1107: .Pp
1.47 nicm 1108: If
1.57 jmc 1109: .Fl t
1110: is present,
1111: .Ar key
1112: in
1113: .Ar key-table
1114: is unbound: the binding for command mode with
1115: .Fl c
1116: or for normal mode without.
1117: .El
1118: .Sh OPTIONS
1119: The appearance and behaviour of
1120: .Nm
1121: may be modified by changing the value of various options.
1122: There are two types of option:
1123: .Em session options
1124: and
1125: .Em window options .
1126: .Pp
1127: Each individual session may have a set of session options, and there is a
1128: separate set of global session options.
1129: Sessions which do not have a particular option configured inherit the value
1130: from the global session options.
1131: Session options are set or unset with the
1132: .Ic set-option
1133: command and may be listed with the
1134: .Ic show-options
1135: command.
1136: The available session options are listed under the
1137: .Ic set-option
1138: command.
1139: .Pp
1140: Similarly, a set of window options is attached to each window, and there is
1141: a set of global window options from which any unset options are inherited.
1142: Window options are altered with the
1143: .Ic set-window-option
1144: command and can be listed with the
1145: .Ic show-window-options
1146: command.
1147: All window options are documented with the
1148: .Ic set-window-option
1149: command.
1150: .Pp
1151: Commands which set options are as follows:
1152: .Bl -tag -width Ds
1.1 nicm 1153: .It Xo Ic set-option
1.58 nicm 1154: .Op Fl agu
1.1 nicm 1155: .Op Fl t Ar target-session
1156: .Ar option Ar value
1157: .Xc
1158: .D1 (alias: Ic set )
1.18 nicm 1159: Set a session option.
1.58 nicm 1160: With
1161: .Fl a ,
1162: and if the option expects a string,
1163: .Ar value
1164: is appended to the existing setting.
1.1 nicm 1165: If
1166: .Fl g
1.18 nicm 1167: is specified, the global session option is set.
1.1 nicm 1168: The
1169: .Fl u
1170: flag unsets an option, so a session inherits the option from the global
1171: options - it is not possible to unset a global option.
1172: .Pp
1.18 nicm 1173: Available session options are:
1.1 nicm 1174: .Bl -tag -width Ds
1.69 nicm 1175: .It Ic base-index Ar index
1176: Set the base index from which an unused index should be searched when a new
1177: window is created.
1178: The default is zero.
1.1 nicm 1179: .It Xo Ic bell-action
1.56 jmc 1180: .Op Ic any | none | current
1.1 nicm 1181: .Xc
1182: Set action on window bell.
1183: .Ic any
1184: means a bell in any window linked to a session causes a bell in the current
1185: window of that session,
1186: .Ic none
1187: means all bells are ignored and
1188: .Ic current
1189: means only bell in windows other than the current window are ignored.
1190: .It Ic buffer-limit Ar number
1191: Set the number of buffers kept for each session; as new buffers are added to
1192: the top of the stack, old ones are removed from the bottom if necessary to
1193: maintain this maximum length.
1194: .It Ic default-command Ar command
1195: Set the command used for new windows (if not specified when the window is
1196: created) to
1.79 nicm 1197: .Ar command ,
1198: which may be any
1199: .Xr sh 1
1200: command.
1.19 nicm 1201: The default is an empty string, which instructs
1202: .Nm
1.79 nicm 1203: to create a login shell using the value of the
1204: .Ic default-shell
1205: option.
1206: .It Ic default-shell Ar path
1207: Specify the default shell.
1208: This is used as the login shell for new windows when the
1209: .Ic default-command
1210: option is set to empty, and must be the full path of the executable.
1211: When started
1212: .Nm
1213: tries to set a default value from the first suitable of the
1.19 nicm 1214: .Ev SHELL
1.79 nicm 1215: environment variable, the shell returned by
1216: .Xr getpwuid 3 ,
1217: or
1218: .Pa /bin/sh .
1219: This option should be configured when
1220: .Nm
1221: is used as a login shell.
1.1 nicm 1222: .It Ic default-path Ar path
1223: Set the default working directory for processes created from keys, or
1224: interactively from the prompt.
1225: The default is the current working directory when the server is started.
1.22 nicm 1226: .It Ic default-terminal Ar terminal
1227: Set the default terminal for new windows created in this session - the
1228: default value of the
1229: .Ev TERM
1230: environment variable.
1231: For
1232: .Nm
1233: to work correctly, this
1234: .Em must
1235: be set to
1236: .Ql screen
1237: or a derivative of it.
1.78 nicm 1238: .It Ic display-panes-colour Ar colour
1239: Set the colour used for the
1240: .Ic display-panes
1241: command.
1242: .It Ic display-panes-time Ar time
1243: Set the time in milliseconds for which the indicators shown by the
1244: .Ic display-panes
1245: command appear.
1.21 nicm 1246: .It Ic display-time Ar time
1.78 nicm 1247: Set the amount of time for which status line messages and other on-screen
1248: indicators are displayed.
1.21 nicm 1249: .Ar time
1250: is in milliseconds.
1.1 nicm 1251: .It Ic history-limit Ar lines
1252: Set the maximum number of lines held in window history.
1253: This setting applies only to new windows - existing window histories are not
1254: resized and retain the limit at the point they were created.
1255: .It Ic lock-after-time Ar number
1.90 nicm 1256: Lock the server (like the
1257: .Ic lock-server
1258: command) after
1.1 nicm 1259: .Ar number
1260: seconds of inactivity.
1261: The default is off (set to 0).
1262: This has no effect as a session option; it must be set as a global option using
1263: .Fl g .
1.90 nicm 1264: .It Ic lock-command Ar command
1265: Command to run when locking each client.
1266: The default is to run
1267: .Xr lock 1
1268: with
1269: .Fl np .
1.1 nicm 1270: .It Ic message-attr Ar attributes
1271: Set status line message attributes, where
1272: .Ar attributes
1273: is either
1274: .Ic default
1275: or a comma-delimited list of one or more of:
1276: .Ic bright
1277: (or
1278: .Ic bold ) ,
1279: .Ic dim ,
1280: .Ic underscore ,
1281: .Ic blink ,
1282: .Ic reverse ,
1283: .Ic hidden ,
1284: or
1285: .Ic italics .
1286: .It Ic message-bg Ar colour
1287: Set status line message background colour, where
1288: .Ar colour
1289: is one of:
1290: .Ic black ,
1291: .Ic red ,
1292: .Ic green ,
1293: .Ic yellow ,
1294: .Ic blue ,
1295: .Ic magenta ,
1296: .Ic cyan ,
1.85 nicm 1297: .Ic white ,
1298: .Ic colour0
1299: to
1300: .Ic colour255
1301: from the 256-colour palette, or
1.1 nicm 1302: .Ic default .
1303: .It Ic message-fg Ar colour
1304: Set status line message foreground colour.
1.89 nicm 1305: .It Ic prefix Ar keys
1306: Set the keys accepted as a prefix key.
1307: .Ar keys
1308: is a comma-separated list of key names, each of which individually behave as
1309: the prefix key.
1.21 nicm 1310: .It Ic repeat-time Ar time
1.1 nicm 1311: Allow multiple commands to be entered without pressing the prefix-key again
1312: in the specified
1.21 nicm 1313: .Ar time
1.1 nicm 1314: milliseconds (the default is 500).
1315: Whether a key repeats may be set when it is bound using the
1316: .Fl r
1317: flag to
1318: .Ic bind-key .
1.52 nicm 1319: Repeat is enabled for the default keys bound to the
1320: .Ic resize-pane
1321: command.
1.1 nicm 1322: .It Xo Ic set-remain-on-exit
1.56 jmc 1323: .Op Ic on | off
1.1 nicm 1324: .Xc
1325: Set the
1326: .Ic remain-on-exit
1327: window option for any windows first created in this session.
1328: .It Xo Ic set-titles
1.56 jmc 1329: .Op Ic on | off
1.1 nicm 1330: .Xc
1.77 stsp 1331: Attempt to set the window title using the \ee]2;...\e007 xterm code if
1.1 nicm 1332: the terminal appears to be an xterm.
1.11 nicm 1333: This option is off by default.
1.6 jmc 1334: Note that elinks
1.1 nicm 1335: will only attempt to set the window title if the STY environment
1336: variable is set.
1.86 nicm 1337: .It Ic set-titles-string Ar string
1338: String used to set the window title if
1339: .Ic set-titles
1340: is on.
1341: Character sequences are replaced as for the
1342: .Ic status-left
1343: option.
1.1 nicm 1344: .It Xo Ic status
1.56 jmc 1345: .Op Ic on | off
1.1 nicm 1346: .Xc
1347: Show or hide the status line.
1348: .It Ic status-attr Ar attributes
1349: Set status line attributes.
1350: .It Ic status-bg Ar colour
1351: Set status line background colour.
1352: .It Ic status-fg Ar colour
1353: Set status line foreground colour.
1354: .It Ic status-interval Ar interval
1355: Update the status bar every
1356: .Ar interval
1357: seconds.
1358: By default, updates will occur every 15 seconds.
1359: A setting of zero disables redrawing at interval.
1.41 nicm 1360: .It Xo Ic status-justify
1.56 jmc 1361: .Op Ic left | centre | right
1.41 nicm 1362: .Xc
1363: Set the position of the window list component of the status line: left, centre
1364: or right justified.
1.1 nicm 1365: .It Xo Ic status-keys
1.56 jmc 1366: .Op Ic vi | emacs
1.1 nicm 1367: .Xc
1.6 jmc 1368: Use vi or emacs-style
1.1 nicm 1369: key bindings in the status line, for example at the command prompt.
1370: Defaults to emacs.
1371: .It Ic status-left Ar string
1372: Display
1373: .Ar string
1374: to the left of the status bar.
1375: .Ar string
1376: will be passed through
1377: .Xr strftime 3
1378: before being used.
1379: By default, the session name is shown.
1380: .Ar string
1.83 nicm 1381: may contain any of the following special character sequences:
1.1 nicm 1382: .Bl -column "Character pair" "Replaced with" -offset indent
1383: .It Sy "Character pair" Ta Sy "Replaced with"
1384: .It Li "#(command)" Ta "First line of command's output"
1.83 nicm 1385: .It Li "#[attributes]" Ta "Colour or attribute change"
1.1 nicm 1386: .It Li "#H" Ta "Hostname of local host"
1.35 nicm 1387: .It Li "#I" Ta "Current window index"
1388: .It Li "#P" Ta "Current pane index"
1.1 nicm 1389: .It Li "#S" Ta "Session name"
1390: .It Li "#T" Ta "Current window title"
1.35 nicm 1391: .It Li "#W" Ta "Current window name"
1.1 nicm 1392: .It Li "##" Ta "A literal" Ql #
1393: .El
1.83 nicm 1394: .Pp
1395: The #(command) form executes
1396: .Ql command
1397: as a shell command and inserts the first line of its output.
1398: #[attributes] allows a comma-separated list of attributes to be specified,
1399: these may be
1400: .Ql fg=colour
1401: to set the foreground colour,
1402: .Ql bg=colour
1403: to set the background colour, or one of the attributes described under the
1404: .Ic message-attr
1405: option.
1406: Examples are:
1407: .Bd -literal -offset indent
1408: #(sysctl vm.loadavg)
1409: #[fg=yellow,bold]#(apm -l)%%#[default] [#S]
1410: .Ed
1.1 nicm 1411: .Pp
1412: Where appropriate, these may be prefixed with a number to specify the maximum
1413: length, for example
1414: .Ql #24T .
1.10 nicm 1415: .Pp
1.12 jmc 1416: By default, UTF-8 in
1.10 nicm 1417: .Ar string
1418: is not interpreted, to enable UTF-8, use the
1419: .Ic status-utf8
1420: option.
1.62 nicm 1421: .It Ic status-left-attr Ar attributes
1.66 jmc 1422: Set the attribute of the left part of the status line.
1.62 nicm 1423: .It Ic status-left-fg Ar colour
1424: Set the foreground colour of the left part of the status line.
1425: .It Ic status-left-bg Ar colour
1426: Set the background colour of the left part of the status line.
1.1 nicm 1427: .It Ic status-left-length Ar length
1428: Set the maximum
1429: .Ar length
1430: of the left component of the status bar.
1431: The default is 10.
1432: .It Ic status-right Ar string
1433: Display
1434: .Ar string
1435: to the right of the status bar.
1436: By default, the date and time will be shown.
1437: As with
1438: .Ic status-left ,
1439: .Ar string
1440: will be passed to
1.10 nicm 1441: .Xr strftime 3 ,
1442: character pairs are replaced, and UTF-8 is dependent on the
1443: .Ic status-utf8
1444: option.
1.62 nicm 1445: .It Ic status-right-attr Ar attributes
1.66 jmc 1446: Set the attribute of the right part of the status line.
1.62 nicm 1447: .It Ic status-right-fg Ar colour
1448: Set the foreground colour of the right part of the status line.
1449: .It Ic status-right-bg Ar colour
1450: Set the background colour of the right part of the status line.
1.1 nicm 1451: .It Ic status-right-length Ar length
1452: Set the maximum
1453: .Ar length
1454: of the right component of the status bar.
1455: The default is 40.
1.10 nicm 1456: .Pp
1457: .It Xo Ic status-utf8
1.56 jmc 1458: .Op Ic on | off
1.10 nicm 1459: .Xc
1460: Instruct
1461: .Nm
1462: to treat top-bit-set characters in the
1463: .Ic status-left
1464: and
1465: .Ic status-right
1466: strings as UTF-8; notably, this is important for wide characters.
1467: This option defaults to off.
1.55 jmc 1468: .It Ic terminal-overrides Ar string
1.54 nicm 1469: Contains a list of entries which override terminal descriptions read using
1470: .Xr terminfo 5 .
1471: .Ar string
1472: is a comma-separated list of items each a colon-separated string made up of a
1473: terminal type pattern (matched using
1474: .Xr fnmatch 3 )
1475: and a set of
1476: .Em name=value
1477: entries.
1478: .Pp
1479: For example, to set the
1480: .Ql clear
1481: .Xr terminfo 5
1482: entry to
1483: .Ql \ee[H\ee[2J
1484: for all terminal types and the
1485: .Ql dch1
1486: entry to
1487: .Ql \ee[P
1.55 jmc 1488: for the
1.54 nicm 1489: .Ql rxvt
1490: terminal type, the option could be set to the string:
1491: .Bd -literal -offset indent
1492: "*:clear=\ee[H\ee[2J,rxvt:dch1=\ee[P"
1493: .Ed
1494: .Pp
1495: The terminal entry value is passed through
1496: .Xr strunvis 3
1497: before interpretation.
1498: The default value forcibly corrects the
1499: .Ql colors
1500: entry for terminals which support 88 or 256 colours:
1501: .Bd -literal -offset indent
1502: "*88col*:colors=88,*256col*:colors=256"
1503: .Ed
1.63 nicm 1504: .It Ic update-environment Ar variables
1505: Set a space-separated string containing a list of environment variables to be
1506: copied into the session environment when a new session is created or an
1507: existing session is attached.
1508: Any variables that do not exist in the source environment are set to be
1509: removed from the session environment (as if
1510: .Fl r
1511: was given to the
1512: .Ic set-environment
1513: command).
1514: The default is
1.75 nicm 1515: "DISPLAY WINDOWID SSH_ASKPASS SSH_AUTH_SOCK SSH_AGENT_PID SSH_CONNECTION".
1.37 nicm 1516: .It Xo Ic visual-activity
1.56 jmc 1517: .Op Ic on | off
1.37 nicm 1518: .Xc
1519: If on, display a status line message when activity occurs in a window
1.39 jmc 1520: for which the
1.37 nicm 1521: .Ic monitor-activity
1522: window option is enabled.
1523: .It Xo Ic visual-bell
1.56 jmc 1524: .Op Ic on | off
1.37 nicm 1525: .Xc
1526: If this option is on, a message is shown on a bell instead of it being passed
1527: through to the terminal (which normally makes a sound).
1528: Also see the
1529: .Ic bell-action
1530: option.
1531: .It Xo Ic visual-content
1.56 jmc 1532: .Op Ic on | off
1.37 nicm 1533: .Xc
1534: Like
1535: .Ic visual-activity ,
1536: display a message when content is present in a window
1.39 jmc 1537: for which the
1.37 nicm 1538: .Ic monitor-content
1539: window option is enabled.
1.1 nicm 1540: .El
1541: .It Xo Ic set-window-option
1.58 nicm 1542: .Op Fl agu
1.1 nicm 1543: .Op Fl t Ar target-window
1544: .Ar option Ar value
1545: .Xc
1546: .D1 (alias: Ic setw )
1.18 nicm 1547: Set a window option.
1.1 nicm 1548: The
1.58 nicm 1549: .Fl a ,
1.1 nicm 1550: .Fl g
1551: and
1552: .Fl u
1553: flags work similarly to the
1554: .Ic set-option
1555: command.
1556: .Pp
1.18 nicm 1557: Supported window options are:
1.56 jmc 1558: .Pp
1559: .Bl -tag -width Ds -compact
1.1 nicm 1560: .It Xo Ic aggressive-resize
1.56 jmc 1561: .Op Ic on | off
1.1 nicm 1562: .Xc
1563: Aggressively resize the chosen window.
1564: This means that
1565: .Nm
1566: will resize the window to the size of the smallest session for which it is the
1567: current window, rather than the smallest session to which it is attached.
1568: The window may resize when the current window is changed on another sessions;
1.6 jmc 1569: this option is good for full-screen programs which support
1570: .Dv SIGWINCH
1571: and poor for interactive programs such as shells.
1.56 jmc 1572: .Pp
1.1 nicm 1573: .It Xo Ic automatic-rename
1.56 jmc 1574: .Op Ic on | off
1.1 nicm 1575: .Xc
1576: Control automatic window renaming.
1577: When this setting is enabled,
1578: .Nm
1579: will attempt - on supported platforms - to rename the window to reflect the
1580: command currently running in it.
1581: This flag is automatically disabled for an individual window when a name
1582: is specified at creation with
1583: .Ic new-window or
1584: .Ic new-session ,
1585: or later with
1586: .Ic rename-window .
1587: It may be switched off globally with:
1588: .Bd -literal -offset indent
1589: set-window-option -g automatic-rename off
1590: .Ed
1.56 jmc 1591: .Pp
1.1 nicm 1592: .It Ic clock-mode-colour Ar colour
1593: Set clock colour.
1.56 jmc 1594: .Pp
1.1 nicm 1595: .It Xo Ic clock-mode-style
1.56 jmc 1596: .Op Ic 12 | 24
1.1 nicm 1597: .Xc
1598: Set clock hour format.
1.56 jmc 1599: .Pp
1.1 nicm 1600: .It Ic force-height Ar height
1601: .It Ic force-width Ar width
1602: Prevent
1603: .Nm
1604: from resizing a window to greater than
1605: .Ar width
1606: or
1607: .Ar height .
1608: A value of zero restores the default unlimited setting.
1.56 jmc 1609: .Pp
1.2 nicm 1610: .It Ic main-pane-width Ar width
1611: .It Ic main-pane-height Ar height
1612: Set the width or height of the main (left or top) pane in the
1613: .Ic main-horizontal
1614: or
1615: .Ic main-vertical
1616: layouts.
1.56 jmc 1617: .Pp
1.1 nicm 1618: .It Ic mode-attr Ar attributes
1619: Set window modes attributes.
1.56 jmc 1620: .Pp
1.1 nicm 1621: .It Ic mode-bg Ar colour
1622: Set window modes background colour.
1.56 jmc 1623: .Pp
1.1 nicm 1624: .It Ic mode-fg Ar colour
1625: Set window modes foreground colour.
1.56 jmc 1626: .Pp
1.1 nicm 1627: .It Xo Ic mode-keys
1.56 jmc 1628: .Op Ic vi | emacs
1.1 nicm 1629: .Xc
1.50 nicm 1630: Use vi or emacs-style key bindings in scroll, copy and choice modes.
1.1 nicm 1631: Key bindings default to emacs.
1.56 jmc 1632: .Pp
1.50 nicm 1633: .It Xo Ic mode-mouse
1.56 jmc 1634: .Op Ic on | off
1.50 nicm 1635: .Xc
1.51 jmc 1636: Mouse state in modes.
1637: If on,
1.50 nicm 1638: .Nm
1639: will respond to mouse clicks by moving the cursor in copy mode or selecting an
1640: option in choice mode.
1.56 jmc 1641: .Pp
1.1 nicm 1642: .It Xo Ic monitor-activity
1.56 jmc 1643: .Op Ic on | off
1.1 nicm 1644: .Xc
1645: Monitor for activity in the window.
1646: Windows with activity are highlighted in the status line.
1.56 jmc 1647: .Pp
1648: .It Ic monitor-content Ar match-string
1.6 jmc 1649: Monitor content in the window.
1650: When
1.16 nicm 1651: .Xr fnmatch 3
1652: pattern
1.1 nicm 1653: .Ar match-string
1654: appears in the window, it is highlighted in the status line.
1.56 jmc 1655: .Pp
1.1 nicm 1656: .It Xo Ic remain-on-exit
1.56 jmc 1657: .Op Ic on | off
1.1 nicm 1658: .Xc
1659: A window with this flag set is not destroyed when the program running in it
1660: exits.
1661: The window may be reactivated with the
1662: .Ic respawn-window
1663: command.
1.56 jmc 1664: .Pp
1.1 nicm 1665: .It Xo Ic utf8
1.56 jmc 1666: .Op Ic on | off
1.1 nicm 1667: .Xc
1668: Instructs
1669: .Nm
1670: to expect UTF-8 sequences to appear in this window.
1.56 jmc 1671: .Pp
1.1 nicm 1672: .It Ic window-status-attr Ar attributes
1673: Set status line attributes for a single window.
1.56 jmc 1674: .Pp
1.1 nicm 1675: .It Ic window-status-bg Ar colour
1676: Set status line background colour for a single window.
1.56 jmc 1677: .Pp
1.1 nicm 1678: .It Ic window-status-fg Ar colour
1679: Set status line foreground colour for a single window.
1.56 jmc 1680: .Pp
1.40 nicm 1681: .It Ic window-status-current-attr Ar attributes
1682: Set status line attributes for the currently active window.
1.56 jmc 1683: .Pp
1.40 nicm 1684: .It Ic window-status-current-bg Ar colour
1685: Set status line background colour for the currently active window.
1.56 jmc 1686: .Pp
1.40 nicm 1687: .It Ic window-status-current-fg Ar colour
1688: Set status line foreground colour for the currently active window.
1.56 jmc 1689: .Pp
1.1 nicm 1690: .It Xo Ic xterm-keys
1.56 jmc 1691: .Op Ic on | off
1.1 nicm 1692: .Xc
1693: If this option is set,
1694: .Nm
1695: will generate
1.57 jmc 1696: .Xr xterm 1 -style
1697: function key sequences; these have a number included to indicate modifiers such
1698: as Shift, Alt or Ctrl.
1699: .El
1700: .It Xo Ic show-options
1701: .Op Fl g
1702: .Op Fl t Ar target-session
1703: .Xc
1704: .D1 (alias: Ic show )
1705: Show the session options for
1706: .Ar target session ,
1707: or the global session options with
1708: .Fl g .
1709: .It Xo Ic show-window-options
1710: .Op Fl g
1711: .Op Fl t Ar target-window
1712: .Xc
1713: .D1 (alias: Ic showw )
1714: List the window options for
1715: .Ar target-window ,
1716: or the global window options if
1717: .Fl g
1718: is used.
1.63 nicm 1719: .El
1720: .Sh ENVIRONMENT
1721: When the server is started,
1722: .Nm
1723: copies the environment into the
1724: .Em global environment ;
1725: in addition, each session has a
1726: .Em session environment .
1727: When a window is created, the session and global environments are merged with
1728: the session environment overriding any variable present in both.
1729: This is the initial environment passed to the new process.
1730: .Pp
1731: The
1732: .Ic update-environment
1733: session option may be used to update the session environment from the client
1734: when a new session is created or an old reattached.
1735: .Nm
1736: also initialises the
1737: .Ev TMUX
1738: variable with some internal information to allow commands to be executed
1739: from inside, and the
1740: .Ev TERM
1741: variable with the correct terminal setting of
1742: .Ql screen .
1743: .Pp
1744: Commands to alter and view the environment are:
1745: .Bl -tag -width Ds
1746: .It Xo Ic set-environment
1747: .Op Fl gru
1748: .Op Fl t Ar target-session
1749: .Ar name Op Ar value
1750: .Xc
1751: Set or unset an environment variable.
1752: If
1753: .Fl g
1754: is used, the change is made in the global environment; otherwise, it is applied
1755: to the session environment for
1756: .Ar target-session .
1757: The
1758: .Fl u
1759: flag unsets a variable.
1760: .Fl r
1761: indicates the variable is to be removed from the environment before starting a
1762: new process.
1763: .It Xo Ic show-environment
1764: .Op Fl g
1765: .Op Fl t Ar target-session
1766: .Xc
1767: Display the environment for
1768: .Ar target-session
1769: or the global environment with
1770: .Fl g .
1771: Variables removed from the environment are prefixed with
1772: .Ql - .
1.57 jmc 1773: .El
1774: .Sh STATUS LINE
1775: .Nm
1776: includes an optional status line which is displayed in the bottom line of each
1777: terminal.
1778: By default, the status line is enabled (it may be disabled with the
1779: .Ic status
1780: session option) and contains, from left-to-right: the name of the current
1781: session in square brackets; the window list; the current window title in double
1782: quotes; and the time and date.
1783: .Pp
1784: The status line is made of three parts: configurable left and right sections
1785: (which may contain dynamic content such as the time or output from a shell
1786: command, see the
1787: .Ic status-left ,
1788: .Ic status-left-length ,
1789: .Ic status-right ,
1790: and
1791: .Ic status-right-length
1792: options below), and a central window list.
1793: The window list shows the index, name and (if any) flag of the windows
1794: present in the current session in ascending numerical order.
1795: The flag is one of the following symbols appended to the window name:
1796: .Bl -column "Symbol" "Meaning" -offset indent
1797: .It Sy "Symbol" Ta Sy "Meaning"
1798: .It Li "*" Ta "Denotes the current window."
1799: .It Li "-" Ta "Marks the last window (previously selected)."
1800: .It Li "#" Ta "Window is monitored and activity has been detected."
1801: .It Li "!" Ta "A bell has occurred in the window."
1802: .It Li "+" Ta "Window is monitored for content and it has appeared."
1803: .El
1804: .Pp
1805: The # symbol relates to the
1806: .Ic monitor-activity
1807: and + to the
1808: .Ic monitor-content
1809: window options.
1810: The window name is printed in inverted colours if an alert (bell, activity or
1811: content) is present.
1812: .Pp
1813: The colour and attributes of the status line may be configured, the entire status line using
1814: the
1815: .Ic status-attr ,
1816: .Ic status-fg
1817: and
1818: .Ic status-bg
1819: session options and individual windows using the
1820: .Ic window-status-attr ,
1821: .Ic window-status-fg
1822: and
1823: .Ic window-status-bg
1824: window options.
1825: .Pp
1826: The status line is automatically refreshed at interval if it has changed, the interval may be
1827: controlled with the
1828: .Ic status-interval
1829: session option.
1830: .Pp
1831: Commands related to the status line are as follows:
1832: .Bl -tag -width Ds
1833: .It Xo Ic command-prompt
1.73 nicm 1834: .Op Fl p Ar prompts
1.57 jmc 1835: .Op Fl t Ar target-client
1836: .Op Ar template
1837: .Xc
1838: Open the command prompt in a client.
1839: This may be used from inside
1840: .Nm
1841: to execute commands interactively.
1842: If
1843: .Ar template
1.73 nicm 1844: is specified, it is used as the command.
1845: If
1846: .Fl p
1847: is given,
1848: .Ar prompts
1849: is a comma-separated list of prompts which are displayed in order; otherwise
1850: a single prompt is displayed, constructed from
1851: .Ar template
1852: if it is present, or
1853: .Ql \&:
1854: if not.
1855: Before the command is executed, the first occurrence of the string
1856: .Ql %%
1.74 jmc 1857: and all occurrences of
1.73 nicm 1858: .Ql %1
1859: are replaced by the response to the first prompt, the second
1860: .Ql %%
1861: and all
1862: .Ql %2
1863: are replaced with the response to the second prompt, and so on for further
1.74 jmc 1864: prompts.
1865: Up to nine prompt responses may be replaced
1866: .Po
1867: .Ql %1
1.73 nicm 1868: to
1.74 jmc 1869: .Ql %9
1870: .Pc .
1.57 jmc 1871: .It Xo Ic confirm-before
1872: .Op Fl t Ar target-client
1873: .Ar command
1874: .Xc
1875: .D1 (alias: Ic confirm )
1876: Ask for confirmation before executing
1877: .Ar command .
1878: This command works only from inside
1879: .Nm .
1880: .It Xo Ic display-message
1881: .Op Fl t Ar target-client
1882: .Op Ar message
1883: .Xc
1884: .D1 (alias: Ic display )
1885: Display a message (see the
1886: .Ic status-left
1887: option below)
1888: in the status line.
1889: .It Ic select-prompt Op Fl t Ar target-client
1890: Open a prompt inside
1891: .Ar target-client
1892: allowing a window index to be entered interactively.
1893: .El
1894: .Sh BUFFERS
1895: .Nm
1896: maintains a stack of
1897: .Em paste buffers
1898: for each session.
1899: Up to the value of the
1900: .Ic buffer-limit
1901: option are kept; when a new buffer is added, the buffer at the bottom of the
1902: stack is removed.
1903: Buffers may be added using
1904: .Ic copy-mode
1905: or the
1906: .Ic set-buffer
1907: command, and pasted into a window using the
1908: .Ic paste-buffer
1909: command.
1910: .Pp
1911: A configurable history buffer is also maintained for each window.
1912: By default, up to 2000 lines are kept; this can be altered with the
1913: .Ic history-limit
1914: option (see the
1915: .Ic set-option
1916: command above).
1917: .Pp
1918: The buffer commands are as follows:
1919: .Bl -tag -width Ds
1920: .It Ic clear-history Op Fl t Ar target-pane
1921: .D1 (alias: Ic clearhist )
1922: Remove and free the history for the specified pane.
1923: .It Xo Ic copy-buffer
1924: .Op Fl a Ar src-index
1925: .Op Fl b Ar dst-index
1926: .Op Fl s Ar src-session
1927: .Op Fl t Ar dst-session
1928: .Xc
1929: .D1 (alias: Ic copyb )
1930: Copy a session paste buffer to another session.
1931: If no sessions are specified, the current one is used instead.
1932: .It Xo Ic delete-buffer
1933: .Op Fl b Ar buffer-index
1934: .Op Fl t Ar target-session
1935: .Xc
1936: .D1 (alias: Ic deleteb )
1937: Delete the buffer at
1938: .Ar buffer-index ,
1939: or the top buffer if not specified.
1940: .It Ic list-buffers Op Fl t Ar target-session
1941: .D1 (alias: Ic lsb )
1942: List the buffers in the given session.
1943: .It Xo Ic load-buffer
1944: .Op Fl b Ar buffer-index
1945: .Op Fl t Ar target-session
1946: .Ar path
1947: .Xc
1948: .D1 (alias: Ic loadb )
1949: Load the contents of the specified paste buffer from
1950: .Ar path .
1951: .It Xo Ic paste-buffer
1952: .Op Fl dr
1953: .Op Fl b Ar buffer-index
1954: .Op Fl t Ar target-window
1955: .Xc
1956: .D1 (alias: Ic pasteb )
1957: Insert the contents of a paste buffer into the current window.
1958: With
1959: .Fl d ,
1960: also delete the paste buffer from the stack.
1961: When output, any linefeed (LF) characters in the paste buffer are replaced with
1962: carriage returns (CR).
1963: This translation may be disabled with the
1964: .Fl r
1965: flag.
1966: .It Xo Ic save-buffer
1967: .Op Fl a
1968: .Op Fl b Ar buffer-index
1969: .Op Fl t Ar target-session
1970: .Ar path
1971: .Xc
1972: .D1 (alias: Ic saveb )
1973: Save the contents of the specified paste buffer to
1974: .Ar path .
1975: The
1976: .Fl a
1977: option appends to rather than overwriting the file.
1978: .It Xo Ic set-buffer
1979: .Op Fl b Ar buffer-index
1980: .Op Fl t Ar target-session
1981: .Ar data
1982: .Xc
1983: .D1 (alias: Ic setb )
1984: Set the contents of the specified buffer to
1985: .Ar data .
1.1 nicm 1986: .It Xo Ic show-buffer
1987: .Op Fl b Ar buffer-index
1988: .Op Fl t Ar target-session
1989: .Xc
1990: .D1 (alias: Ic showb )
1991: Display the contents of the specified buffer.
1.57 jmc 1992: .El
1993: .Sh MISCELLANEOUS
1994: .Pp
1995: Miscellaneous commands are as follows:
1996: .Bl -tag -width Ds
1.72 nicm 1997: .It Ic clock-mode Op Fl t Ar target-pane
1.57 jmc 1998: Display a large clock.
1999: .It Ic if-shell Ar shell-command command
2000: .D1 (alias: Ic if )
2001: Execute
2002: .Ar command
2003: if
2004: .Ar shell-command
2005: returns success.
2006: .It Ic lock-server
2007: .D1 (alias: Ic lock )
1.90 nicm 2008: Lock each client individually by running the command specified by the
2009: .Ic lock-command
2010: option.
1.87 nicm 2011: .It Ic run-shell Ar command
2012: .D1 (alias: Ic run )
2013: Execute
2014: .Ar command
2015: without creating a window.
2016: Any output to stdout is displayed in output mode.
2017: If
1.88 jmc 2018: .Ar command
1.87 nicm 2019: doesn't return success, the exit status is also displayed.
1.57 jmc 2020: .It Ic server-info
2021: .D1 (alias: Ic info )
2022: Show server information and terminal details.
1.1 nicm 2023: .El
2024: .Sh FILES
1.26 nicm 2025: .Bl -tag -width "/etc/tmux.confXXX" -compact
1.1 nicm 2026: .It Pa ~/.tmux.conf
1.6 jmc 2027: Default
1.1 nicm 2028: .Nm
1.6 jmc 2029: configuration file.
1.26 nicm 2030: .It Pa /etc/tmux.conf
2031: System-wide configuration file.
1.1 nicm 2032: .El
1.57 jmc 2033: .Sh EXAMPLES
2034: To create a new
2035: .Nm
2036: session running
2037: .Xr vi 1 :
2038: .Pp
2039: .Dl $ tmux new-session vi
2040: .Pp
2041: Most commands have a shorter form, known as an alias.
2042: For new-session, this is
2043: .Ic new :
2044: .Pp
2045: .Dl $ tmux new vi
2046: .Pp
2047: Alternatively, the shortest unambiguous form of a command is accepted.
2048: If there are several options, they are listed:
2049: .Bd -literal -offset indent
2050: $ tmux n
2051: ambiguous command: n, could be: new-session, new-window, next-window
2052: .Ed
2053: .Pp
2054: Within an active session, a new window may be created by typing
2055: .Ql C-b c
2056: (Ctrl
2057: followed by the
2058: .Ql b
2059: key
2060: followed by the
2061: .Ql c
2062: key).
2063: .Pp
2064: Windows may be navigated with:
2065: .Ql C-b 0
2066: (to select window 0),
2067: .Ql C-b 1
2068: (to select window 1), and so on;
2069: .Ql C-b n
2070: to select the next window; and
2071: .Ql C-b p
2072: to select the previous window.
2073: .Pp
2074: A session may be detached using
2075: .Ql C-b d
1.64 nicm 2076: (or by an external event such as
2077: .Xr ssh 1
2078: disconnection) and reattached with:
1.57 jmc 2079: .Pp
2080: .Dl $ tmux attach-session
2081: .Pp
2082: Typing
2083: .Ql C-b \&?
2084: lists the current key bindings in the current window; up and down may be used
2085: to navigate the list or
2086: .Ql q
2087: to exit from it.
2088: .Pp
2089: Commands to be run when the
2090: .Nm
2091: server is started may be placed in the
2092: .Pa ~/.tmux.conf
2093: configuration file.
2094: Common examples include:
2095: .Pp
2096: Changing the default prefix key:
2097: .Bd -literal -offset indent
2098: set-option -g prefix C-a
2099: unbind-key C-b
2100: bind-key C-a send-prefix
2101: .Ed
2102: .Pp
2103: Turning the status line off, or changing its colour:
2104: .Bd -literal -offset indent
2105: set-option -g status off
2106: set-option -g status-bg blue
2107: .Ed
2108: .Pp
2109: Setting other options, such as the default command,
2110: or locking after 30 minutes of inactivity:
2111: .Bd -literal -offset indent
2112: set-option -g default-command "exec /bin/ksh"
2113: set-option -g lock-after-time 1800
2114: .Ed
2115: .Pp
2116: Creating new key bindings:
2117: .Bd -literal -offset indent
2118: bind-key b set-option status
2119: bind-key / command-prompt "split-window 'exec man %%'"
1.73 nicm 2120: bind-key S command-prompt "new-window -n %1 'ssh %1'"
1.57 jmc 2121: .Ed
1.1 nicm 2122: .Sh SEE ALSO
2123: .Xr pty 4
2124: .Sh AUTHORS
2125: .An Nicholas Marriott Aq nicm@users.sourceforge.net