version 1.739, 2020/04/12 20:16:36 |
version 1.740, 2020/04/13 07:25:33 |
|
|
.Pp |
.Pp |
Hooks are stored as array options, members of the array are executed in |
Hooks are stored as array options, members of the array are executed in |
order when the hook is triggered. |
order when the hook is triggered. |
|
Like options different hooks may be global or belong to a session, window or pane. |
Hooks may be configured with the |
Hooks may be configured with the |
.Ic set-hook |
.Ic set-hook |
or |
or |
|
|
Hooks are managed with these commands: |
Hooks are managed with these commands: |
.Bl -tag -width Ds |
.Bl -tag -width Ds |
.It Xo Ic set-hook |
.It Xo Ic set-hook |
.Op Fl agRu |
.Op Fl agpRuw |
.Op Fl t Ar target-session |
.Op Fl t Ar target-pane |
.Ar hook-name |
.Ar hook-name |
.Ar command |
.Ar command |
.Xc |
.Xc |
|
|
.Ar hook-name |
.Ar hook-name |
to |
to |
.Ar command . |
.Ar command . |
If |
The flags are the same as for |
.Fl g |
.Ic set-option . |
is given, |
|
.Em hook-name |
|
is added to the global list of hooks, otherwise it is added to the session |
|
hooks (for |
|
.Ar target-session |
|
with |
|
.Fl t ) . |
|
.Fl a |
|
appends to a hook. |
|
Like options, session hooks inherit from the global ones. |
|
.Pp |
.Pp |
With |
With |
.Fl R , |
.Fl R , |
|
|
.Ar hook-name |
.Ar hook-name |
immediately. |
immediately. |
.It Xo Ic show-hooks |
.It Xo Ic show-hooks |
.Op Fl g |
.Op Fl gpw |
.Op Fl t Ar target-session |
.Op Fl t Ar target-pane |
.Xc |
.Xc |
Shows the global list of hooks with |
Shows hooks. |
.Fl g , |
The flags are the same as for |
otherwise the session hooks. |
.Ic show-options . |
.El |
.El |
.Sh MOUSE SUPPORT |
.Sh MOUSE SUPPORT |
If the |
If the |