mirror of
git://git.code.sf.net/p/zsh/code
synced 2025-09-11 00:51:05 +02:00
23439: complete sessions for -dr, -dR, -Dr, -DR, -dx, and -Dx.
This commit is contained in:
parent
a11fbaf68c
commit
6463aa5e53
2 changed files with 16 additions and 0 deletions
|
@ -1,3 +1,8 @@
|
||||||
|
2007-05-14 Clint Adams <clint@zsh.org>
|
||||||
|
|
||||||
|
* Alexander Myodov: 23439: Completion/Unix/Command/_screen:
|
||||||
|
complete sessions for -dr, -dR, -Dr, -DR, -dx, and -Dx.
|
||||||
|
|
||||||
2007-05-14 Peter Stephenson <pws@csr.com>
|
2007-05-14 Peter Stephenson <pws@csr.com>
|
||||||
|
|
||||||
* users/11484: Functions/Misc/zmv: allow renaming $f to $g
|
* users/11484: Functions/Misc/zmv: allow renaming $f to $g
|
||||||
|
|
|
@ -75,7 +75,11 @@ _arguments -C \
|
||||||
'-p[preselect the named window]:window number or name:((\=\:windowlist -\:blank\ window \:window\ number))' \
|
'-p[preselect the named window]:window number or name:((\=\:windowlist -\:blank\ window \:window\ number))' \
|
||||||
'-q[quiet startup, exit with non-zero return code if unsuccessful]' \
|
'-q[quiet startup, exit with non-zero return code if unsuccessful]' \
|
||||||
'-r[reattach to a detached screen process]: :->detached-sessions' \
|
'-r[reattach to a detached screen process]: :->detached-sessions' \
|
||||||
|
'-Dr: :->any-sessions' \
|
||||||
|
'-dr: :->any-sessions' \
|
||||||
'-R[reattach if possible, otherwise start a new session]: :->detached-sessions' \
|
'-R[reattach if possible, otherwise start a new session]: :->detached-sessions' \
|
||||||
|
'-DR: :->any-sessions' \
|
||||||
|
'-dR: :->any-sessions' \
|
||||||
'-s[shell to execute rather than $SHELL]:shell name: _command_names -e' \
|
'-s[shell to execute rather than $SHELL]:shell name: _command_names -e' \
|
||||||
'-S[name this session <pid>.sockname instead of <pid>.<tty>.<host>]:session name' \
|
'-S[name this session <pid>.sockname instead of <pid>.<tty>.<host>]:session name' \
|
||||||
"-t[set title (window's name)]:title" \
|
"-t[set title (window's name)]:title" \
|
||||||
|
@ -84,6 +88,8 @@ _arguments -C \
|
||||||
'(-)-v[print screen version]' \
|
'(-)-v[print screen version]' \
|
||||||
'(-)-wipe[do nothing, clean up SockDir]' \
|
'(-)-wipe[do nothing, clean up SockDir]' \
|
||||||
'-x[attach to a not detached screen (multi display mode)]: :->attached-sessions' \
|
'-x[attach to a not detached screen (multi display mode)]: :->attached-sessions' \
|
||||||
|
'-Dx: :->any-sessions' \
|
||||||
|
'-dx: :->any-sessions' \
|
||||||
'-X[execute command as a screen command in the specified session]:screencmd:(${scr_cmds[@]})' \
|
'-X[execute command as a screen command in the specified session]:screencmd:(${scr_cmds[@]})' \
|
||||||
'*::arguments: _normal'
|
'*::arguments: _normal'
|
||||||
|
|
||||||
|
@ -101,6 +107,11 @@ if [[ -n $state ]]; then
|
||||||
-ls)"}:#*[Dd]etached*}##[[:blank:]]}%%[[:blank:]]*}
|
-ls)"}:#*[Dd]etached*}##[[:blank:]]}%%[[:blank:]]*}
|
||||||
)
|
)
|
||||||
;;
|
;;
|
||||||
|
any-sessions)
|
||||||
|
sessions=(
|
||||||
|
${${${(M)${(f)"$(_call_program screen-sessions $words[1] \
|
||||||
|
-ls)"}:#*tached*}##[[:blank:]]}%%[[:blank:]]*}
|
||||||
|
)
|
||||||
esac
|
esac
|
||||||
|
|
||||||
# check if initial PID is necessary to make sessions unambiguous
|
# check if initial PID is necessary to make sessions unambiguous
|
||||||
|
|
Loading…
Reference in a new issue