From dc717207097bf4840e4145af999418658b5ca053 Mon Sep 17 00:00:00 2001 From: Peter Stephenson Date: Wed, 2 Dec 2009 09:56:42 +0000 Subject: 27446: Frank: tmux completion update 27447: document change for waiting for $! --- ChangeLog | 6 +++++- Completion/Unix/Command/_tmux | 17 ++++++++++++++++- Doc/Zsh/options.yo | 5 +++++ 3 files changed, 26 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index 103dbccf3..c9b6303b0 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,9 @@ 2009-12-02 Peter Stephenson + * 27447: Doc/Zsh/options.yo: document 27442. + + * Frank: 27446: Completion/Unix/Command/_tmux: update. + * 27442 plus tweak: Src/exec.c, Src/init.c, Src/jobs.c, Src/signals.c: return status for last background job from wait even if it's already exited, but only if POSIX_JOBS @@ -12420,5 +12424,5 @@ ***************************************************** * This is used by the shell to define $ZSH_PATCHLEVEL -* $Revision: 1.4828 $ +* $Revision: 1.4829 $ ***************************************************** diff --git a/Completion/Unix/Command/_tmux b/Completion/Unix/Command/_tmux index 10a1eb223..481a34bf9 100644 --- a/Completion/Unix/Command/_tmux +++ b/Completion/Unix/Command/_tmux @@ -57,6 +57,7 @@ _tmux_aliasmap=( new new-session refresh refresh-client rename rename-session + showmsgs show-messages source source-file start start-server suspendc suspend-client @@ -105,7 +106,8 @@ _tmux_aliasmap=( showw show-window-options # environment - #no aliases so far in this category + setenv set-environment + showenv show-environment # status line confirm confirm-before @@ -334,6 +336,7 @@ function _tmux-display-message() { [[ -n ${tmux_describe} ]] && print "Display a message in the status line" && return local -a args args=( + '-p[Print message to stdout]' '-t[Choose a target client]:clients:__tmux-clients' '*:: :->msg' ) @@ -923,6 +926,12 @@ function _tmux-show-environment() { _arguments ${args} } +function _tmux-show-messages() { + [[ -n ${tmux_describe} ]] && print "Show client"\'"s message log" && return + args=('-t[Choose target client]:client:__tmux-clients') + _arguments ${args} +} + function _tmux-show-options() { [[ -n ${tmux_describe} ]] && print "Show session options" && return local -a args @@ -1178,6 +1187,7 @@ function __tmux-option-guard() { 'message-attr:__tmux-attributes' 'message-bg:__tmux-colours' 'message-fg:__tmux-colours' + 'message-limit:'${int_guard} 'mouse-select-pane:DESC:on off' 'prefix:MSG:comma-seperated key list' 'repeat-time:'${int_guard} @@ -1233,7 +1243,9 @@ function __tmux-option-guard() { 'window-status-current-attr:__tmux-attributes' 'window-status-current-bg:__tmux-colours' 'window-status-current-fg:__tmux-colours' + 'window-status-current-format:MSG:status format string' 'window-status-fg:__tmux-colours' + 'window-status-format:MSG:status format string' 'xterm-keys:DESC:on off' ) fi @@ -1280,6 +1292,7 @@ function __tmux-options() { 'message-attr:Set status line message attributes' 'message-bg:Set status line message background colour' 'message-fg:Set status line message foreground colour' + 'message-limit:Set size of message log per client' 'mouse-select-pane:Make mouse clicks select window panes' 'prefix:Comma seperated line of keys accepted as prefix key' 'repeat-time:Time for multiple commands without prefix-key presses' @@ -1376,7 +1389,9 @@ function __tmux-window-options() { 'window-status-current-attr:Set status line attributes for active window' 'window-status-current-bg:Set status line background for active window' 'window-status-current-fg:Set status line foreground for active window' + 'window-status-current-format:Set status line format for active window' 'window-status-fg:Set status line foreground for a window' + 'window-status-format:Set status line format for all but the active window' 'xterm-keys:Generate xterm-style function key sequences' ) _describe -t tmux-window-options 'tmux window option' tmux_window_options diff --git a/Doc/Zsh/options.yo b/Doc/Zsh/options.yo index 555d416e6..46e21d672 100644 --- a/Doc/Zsh/options.yo +++ b/Doc/Zsh/options.yo @@ -1324,6 +1324,11 @@ When the option is not set, job information from the parent shell is saved for output within a subshell (for example, within a pipeline). When the option is set, the output of tt(jobs) is empty until a job is started within the subshell. + +When the option is set, it becomes possible to use the tt(wait) builtin to +wait for the last job started in the background (as given by tt($!)) even +if that job has already exited. This works even if the option is turned +on temporarily around the use of the tt(wait) builtin. ) enditem() -- cgit 1.4.1