[BACK]Return to tmux.1 CVS log [TXT][DIR] Up to [local] / src / usr.bin / tmux

Diff for /src/usr.bin/tmux/tmux.1 between version 1.933 and 1.934

version 1.933, 2023/09/16 16:18:29 version 1.934, 2023/12/27 20:20:50
Line 140 
Line 140 
 loads the system configuration file from  loads the system configuration file from
 .Pa /etc/tmux.conf ,  .Pa /etc/tmux.conf ,
 if present, then looks for a user configuration file at  if present, then looks for a user configuration file at
 .Pa ~/.tmux.conf .  .Pa \[ti]/.tmux.conf .
 .Pp  .Pp
 The configuration file is a set of  The configuration file is a set of
 .Nm  .Nm
Line 287 
Line 287 
 Split the current pane into two, left and right.  Split the current pane into two, left and right.
 .It &  .It &
 Kill the current window.  Kill the current window.
 .It '  .It \[aq]
 Prompt for a window index to select.  Prompt for a window index to select.
 .It \&(  .It \&(
 Switch the attached client to the previous session.  Switch the attached client to the previous session.
Line 359 
Line 359 
 Swap the current pane with the previous pane.  Swap the current pane with the previous pane.
 .It }  .It }
 Swap the current pane with the next pane.  Swap the current pane with the next pane.
 .It ~  .It \[ti]
 Show previous messages from  Show previous messages from
 .Nm ,  .Nm ,
 if any.  if any.
Line 405 
Line 405 
 For example, the same  For example, the same
 .Ic set-option  .Ic set-option
 command run from the shell prompt, from  command run from the shell prompt, from
 .Pa ~/.tmux.conf  .Pa \[ti]/.tmux.conf
 and bound to a key may look like:  and bound to a key may look like:
 .Bd -literal -offset indent  .Bd -literal -offset indent
 $ tmux set-option -g status-style bg=cyan  $ tmux set-option -g status-style bg=cyan
Line 458 
Line 458 
 .Ql command queue .  .Ql command queue .
 A global command queue not attached to any client is used on startup  A global command queue not attached to any client is used on startup
 for configuration files like  for configuration files like
 .Pa ~/.tmux.conf .  .Pa \[ti]/.tmux.conf .
 Parsed commands added to the queue are executed in order.  Parsed commands added to the queue are executed in order.
 Some commands, like  Some commands, like
 .Ic if-shell  .Ic if-shell
Line 530 
Line 530 
 .Pp  .Pp
 Or:  Or:
 .Bd -literal -offset indent  .Bd -literal -offset indent
 $ tmux neww ';' splitw  $ tmux neww \[aq];\[aq] splitw
 .Ed  .Ed
 .Pp  .Pp
 Or from the tmux command prompt:  Or from the tmux command prompt:
Line 548 
Line 548 
 .Pp  .Pp
 Or:  Or:
 .Bd -literal -offset indent  .Bd -literal -offset indent
 $ tmux 'neww;' splitw  $ tmux \[aq]neww;\[aq] splitw
 .Ed  .Ed
 .Pp  .Pp
 As in these examples, when running tmux from the shell extra care must be taken  As in these examples, when running tmux from the shell extra care must be taken
Line 560 
Line 560 
 For  For
 .Xr sh 1  .Xr sh 1
 this typically means quoted (such as  this typically means quoted (such as
 .Ql neww ';' splitw )  .Ql neww \[aq];\[aq] splitw )
 or escaped (such as  or escaped (such as
 .Ql neww \e\e\e\e; splitw ) .  .Ql neww \e\e\e\e; splitw ) .
 .It  .It
Line 570 
Line 570 
 .Nm ;  .Nm ;
 for example:  for example:
 .Bd -literal -offset indent  .Bd -literal -offset indent
 $ tmux neww 'foo\e\e;' bar  $ tmux neww \[aq]foo\e\e;\[aq] bar
 $ tmux neww foo\e\e\e\e; bar  $ tmux neww foo\e\e\e\e; bar
 .Ed  .Ed
 .It  .It
 Semicolons that are not individual tokens or trailing another token should only  Semicolons that are not individual tokens or trailing another token should only
 be escaped once according to shell conventions; for example:  be escaped once according to shell conventions; for example:
 .Bd -literal -offset indent  .Bd -literal -offset indent
 $ tmux neww 'foo-;-bar'  $ tmux neww \[aq]foo-;-bar\[aq]
 $ tmux neww foo-\e\e;-bar  $ tmux neww foo-\e\e;-bar
 .Ed  .Ed
 .El  .El
Line 590 
Line 590 
 This is called line continuation and applies both inside and outside quoted  This is called line continuation and applies both inside and outside quoted
 strings and in comments, but not inside braces.  strings and in comments, but not inside braces.
 .Pp  .Pp
 Command arguments may be specified as strings surrounded by single (') quotes,  Command arguments may be specified as strings surrounded by single (\[aq]) quotes,
 double quotes (") or braces ({}).  double quotes (\[dq]) or braces ({}).
 .\" "  .\" "
 This is required when the argument contains any special character.  This is required when the argument contains any special character.
 Single and double quoted strings cannot span multiple lines except with line  Single and double quoted strings cannot span multiple lines except with line
Line 606 
Line 606 
 .Sx GLOBAL AND SESSION ENVIRONMENT  .Sx GLOBAL AND SESSION ENVIRONMENT
 section).  section).
 .It  .It
 A leading ~ or ~user is expanded to the home directory of the current or  A leading \[ti] or \[ti]user is expanded to the home directory of the current or
 specified user.  specified user.
 .It  .It
 \euXXXX or \euXXXXXXXX is replaced by the Unicode codepoint corresponding to  \euXXXX or \euXXXXXXXX is replaced by the Unicode codepoint corresponding to
Line 638 
Line 638 
 needed when using {}:  needed when using {}:
 .Bd -literal -offset indent  .Bd -literal -offset indent
 if-shell true {  if-shell true {
     display -p 'brace-dollar-foo: }$foo'      display -p \[aq]brace-dollar-foo: }$foo\[aq]
 }  }
   
 if-shell true "display -p 'brace-dollar-foo: }\e$foo'"  if-shell true "display -p \[aq]brace-dollar-foo: }\e$foo\[aq]"
 .Ed  .Ed
 .Pp  .Pp
 Braces may be enclosed inside braces, for example:  Braces may be enclosed inside braces, for example:
Line 892 
Line 892 
 or  or
 .Ql {marked}  .Ql {marked}
 (alternative form  (alternative form
 .Ql ~ )  .Ql \[ti] )
 to specify the marked pane (see  to specify the marked pane (see
 .Ic select-pane  .Ic select-pane
 .Fl m ) .  .Fl m ) .
Line 932 
Line 932 
 commands.  commands.
 This may be a single argument passed to the shell, for example:  This may be a single argument passed to the shell, for example:
 .Bd -literal -offset indent  .Bd -literal -offset indent
 new-window 'vi ~/.tmux.conf'  new-window \[aq]vi \[ti]/.tmux.conf\[aq]
 .Ed  .Ed
 .Pp  .Pp
 Will run:  Will run:
 .Bd -literal -offset indent  .Bd -literal -offset indent
 /bin/sh -c 'vi ~/.tmux.conf'  /bin/sh -c \[aq]vi \[ti]/.tmux.conf\[aq]
 .Ed  .Ed
 .Pp  .Pp
 Additionally, the  Additionally, the
Line 954 
Line 954 
 This can avoid issues with shell quoting.  This can avoid issues with shell quoting.
 For example:  For example:
 .Bd -literal -offset indent  .Bd -literal -offset indent
 $ tmux new-window vi ~/.tmux.conf  $ tmux new-window vi \[ti]/.tmux.conf
 .Ed  .Ed
 .Pp  .Pp
 Will run  Will run
Line 989 
Line 989 
   
 new-window ; split-window -d  new-window ; split-window -d
   
 bind-key R source-file ~/.tmux.conf \e; \e  bind-key R source-file \[ti]/.tmux.conf \e; \e
         display-message "source-file done"          display-message "source-file done"
 .Ed  .Ed
 .Pp  .Pp
Line 1000 
Line 1000 
   
 $ tmux new-window \e; split-window -d  $ tmux new-window \e; split-window -d
   
 $ tmux new-session -d 'vi ~/.tmux.conf' \e; split-window -d \e; attach  $ tmux new-session -d \[aq]vi \[ti]/.tmux.conf\[aq] \e; split-window -d \e; attach
 .Ed  .Ed
 .Sh CLIENTS AND SESSIONS  .Sh CLIENTS AND SESSIONS
 The  The
Line 1581 
Line 1581 
 .Nm  .Nm
 server will exit with no sessions, this is only useful if a session is created  server will exit with no sessions, this is only useful if a session is created
 in  in
 .Pa ~/.tmux.conf ,  .Pa \[ti]/.tmux.conf ,
 .Ic exit-empty  .Ic exit-empty
 is turned off, or another command is run as part of the same command sequence.  is turned off, or another command is run as part of the same command sequence.
 For example:  For example:
Line 2171 
Line 2171 
 $ tmux list-windows  $ tmux list-windows
 0: ksh [159x48]  0: ksh [159x48]
     layout: bb62,159x48,0,0{79x48,0,0,79x48,80,0}      layout: bb62,159x48,0,0{79x48,0,0,79x48,80,0}
 $ tmux select-layout 'bb62,159x48,0,0{79x48,0,0,79x48,80,0}'  $ tmux select-layout \[aq]bb62,159x48,0,0{79x48,0,0,79x48,80,0}\[aq]
 .Ed  .Ed
 .Pp  .Pp
 .Nm  .Nm
Line 2311 
Line 2311 
 and the result executed as a command.  and the result executed as a command.
 If  If
 .Ar template  .Ar template
 is not given, "detach-client -t '%%'" is used.  is not given, "detach-client -t \[aq]%%\[aq]" is used.
 .Pp  .Pp
 .Fl O  .Fl O
 specifies the initial sort field: one of  specifies the initial sort field: one of
Line 2396 
Line 2396 
 and the result executed as a command.  and the result executed as a command.
 If  If
 .Ar template  .Ar template
 is not given, "switch-client -t '%%'" is used.  is not given, "switch-client -t \[aq]%%\[aq]" is used.
 .Pp  .Pp
 .Fl O  .Fl O
 specifies the initial sort field: one of  specifies the initial sort field: one of
Line 2508 
Line 2508 
 substituted by the pane ID.  substituted by the pane ID.
 The default  The default
 .Ar template  .Ar template
 is "select-pane -t '%%'".  is "select-pane -t \[aq]%%\[aq]".
 With  With
 .Fl b ,  .Fl b ,
 other commands are not blocked from running until the indicator is closed.  other commands are not blocked from running until the indicator is closed.
Line 2870 
Line 2870 
 option only opens a new pipe if no previous pipe exists, allowing a pipe to  option only opens a new pipe if no previous pipe exists, allowing a pipe to
 be toggled with a single key, for example:  be toggled with a single key, for example:
 .Bd -literal -offset indent  .Bd -literal -offset indent
 bind-key C-p pipe-pane -o 'cat >>~/output.#I-#P'  bind-key C-p pipe-pane -o \[aq]cat >>\[ti]/output.#I-#P\[aq]
 .Ed  .Ed
 .Tg prevl  .Tg prevl
 .It Xo Ic previous-layout  .It Xo Ic previous-layout
Line 3174 
Line 3174 
 .Pp  .Pp
 An empty  An empty
 .Ar shell-command  .Ar shell-command
 ('') will create a pane with no command running in it.  (\[aq]\[aq]) will create a pane with no command running in it.
 Output can be sent to such a pane with the  Output can be sent to such a pane with the
 .Ic display-message  .Ic display-message
 command.  command.
Line 3301 
Line 3301 
 Note that to bind the  Note that to bind the
 .Ql \&"  .Ql \&"
 or  or
 .Ql '  .Ql \[aq]
 keys, quotation marks are necessary, for example:  keys, quotation marks are necessary, for example:
 .Bd -literal -offset indent  .Bd -literal -offset indent
 bind-key '"' split-window  bind-key \[aq]"\[aq] split-window
 bind-key "'" new-window  bind-key "\[aq]" new-window
 .Ed  .Ed
 .Pp  .Pp
 A command bound to the  A command bound to the
Line 3701 
Line 3701 
 .Ar value .  .Ar value .
 For example, after:  For example, after:
 .Pp  .Pp
 .Dl set -s command-alias[100] zoom='resize-pane -Z'  .Dl set -s command-alias[100] zoom=\[aq]resize-pane -Z\[aq]
 .Pp  .Pp
 Using:  Using:
 .Pp  .Pp
Line 3939 
Line 3939 
 .Pp  .Pp
 For example:  For example:
 .Bd -literal -offset indent  .Bd -literal -offset indent
 set -s user-keys[0] "\ee[5;30012~"  set -s user-keys[0] "\ee[5;30012\[ti]"
 bind User0 resize-pane -L 3  bind User0 resize-pane -L 3
 .Ed  .Ed
 .El  .El
Line 4838 
Line 4838 
 .Fl H .  .Fl H .
 The following two commands are equivalent:  The following two commands are equivalent:
 .Bd -literal -offset indent.  .Bd -literal -offset indent.
 set-hook -g pane-mode-changed[42] 'set -g status-left-style bg=red'  set-hook -g pane-mode-changed[42] \[aq]set -g status-left-style bg=red\[aq]
 set-option -g pane-mode-changed[42] 'set -g status-left-style bg=red'  set-option -g pane-mode-changed[42] \[aq]set -g status-left-style bg=red\[aq]
 .Ed  .Ed
 .Pp  .Pp
 Setting a hook without specifying an array index clears the hook and sets the  Setting a hook without specifying an array index clears the hook and sets the
Line 5778 
Line 5778 
 .Ic allow-rename  .Ic allow-rename
 option is turned on):  option is turned on):
 .Bd -literal -offset indent  .Bd -literal -offset indent
 $ printf '\e033kWINDOW_NAME\e033\e\e'  $ printf \[aq]\e033kWINDOW_NAME\e033\e\e\[aq]
 .Ed  .Ed
 .It  .It
 Automatic renaming, which sets the name to the active command in the window's  Automatic renaming, which sets the name to the active command in the window's
Line 5791 
Line 5791 
 When a pane is first created, its title is the hostname.  When a pane is first created, its title is the hostname.
 A pane's title can be set via the title setting escape sequence, for example:  A pane's title can be set via the title setting escape sequence, for example:
 .Bd -literal -offset indent  .Bd -literal -offset indent
 $ printf '\e033]2;My Title\e033\e\e'  $ printf \[aq]\e033]2;My Title\e033\e\e\[aq]
 .Ed  .Ed
 .Pp  .Pp
 It can also be modified with the  It can also be modified with the
Line 5916 
Line 5916 
 .It Li "-" Ta "Marks the last window (previously selected)."  .It Li "-" Ta "Marks the last window (previously selected)."
 .It Li "#" Ta "Window activity is monitored and activity has been detected."  .It Li "#" Ta "Window activity is monitored and activity has been detected."
 .It Li "\&!" Ta "Window bells are monitored and a bell has occurred in the window."  .It Li "\&!" Ta "Window bells are monitored and a bell has occurred in the window."
 .It Li "~" Ta "The window has been silent for the monitor-silence interval."  .It Li "\[ti]" Ta "The window has been silent for the monitor-silence interval."
 .It Li "M" Ta "The window contains the marked pane."  .It Li "M" Ta "The window contains the marked pane."
 .It Li "Z" Ta "The window's active pane is zoomed."  .It Li "Z" Ta "The window's active pane is zoomed."
 .El  .El
Line 6451 
Line 6451 
 and the result executed as a command.  and the result executed as a command.
 If  If
 .Ar template  .Ar template
 is not given, "paste-buffer -b '%%'" is used.  is not given, "paste-buffer -b \[aq]%%\[aq]" is used.
 .Pp  .Pp
 .Fl O  .Fl O
 specifies the initial sort field: one of  specifies the initial sort field: one of
Line 6750 
Line 6750 
 to change the cursor colour from inside  to change the cursor colour from inside
 .Nm :  .Nm :
 .Bd -literal -offset indent  .Bd -literal -offset indent
 $ printf '\e033]12;red\e033\e\e'  $ printf \[aq]\e033]12;red\e033\e\e\[aq]
 .Ed  .Ed
 .Pp  .Pp
 The colour is an  The colour is an
Line 6806 
Line 6806 
 If set, a sequence such as this may be used  If set, a sequence such as this may be used
 to change the cursor to an underline:  to change the cursor to an underline:
 .Bd -literal -offset indent  .Bd -literal -offset indent
 $ printf '\e033[4 q'  $ printf \[aq]\e033[4 q\[aq]
 .Ed  .Ed
 .Pp  .Pp
 If  If
Line 7125 
Line 7125 
 .El  .El
 .Sh FILES  .Sh FILES
 .Bl -tag -width "/etc/tmux.confXXX" -compact  .Bl -tag -width "/etc/tmux.confXXX" -compact
 .It Pa ~/.tmux.conf  .It Pa \[ti]/.tmux.conf
 Default  Default
 .Nm  .Nm
 configuration file.  configuration file.
Line 7191 
Line 7191 
 Commands to be run when the  Commands to be run when the
 .Nm  .Nm
 server is started may be placed in the  server is started may be placed in the
 .Pa ~/.tmux.conf  .Pa \[ti]/.tmux.conf
 configuration file.  configuration file.
 Common examples include:  Common examples include:
 .Pp  .Pp
Line 7218 
Line 7218 
 Creating new key bindings:  Creating new key bindings:
 .Bd -literal -offset indent  .Bd -literal -offset indent
 bind-key b set-option status  bind-key b set-option status
 bind-key / command-prompt "split-window 'exec man %%'"  bind-key / command-prompt "split-window \[aq]exec man %%\[aq]"
 bind-key S command-prompt "new-window -n %1 'ssh %1'"  bind-key S command-prompt "new-window -n %1 \[aq]ssh %1\[aq]"
 .Ed  .Ed
 .Sh SEE ALSO  .Sh SEE ALSO
 .Xr pty 4  .Xr pty 4

Legend:
Removed from v.1.933  
changed lines
  Added in v.1.934