about summary refs log tree commit diff
path: root/Completion/Unix
diff options
context:
space:
mode:
authorDoug Kearns <dkearns@users.sourceforge.net>2004-11-27 15:20:28 +0000
committerDoug Kearns <dkearns@users.sourceforge.net>2004-11-27 15:20:28 +0000
commitfdae219903892548d9a8facfdd20d989bc24870e (patch)
treedabe1d3739bf984989c86d57d1497b28951b1cca /Completion/Unix
parentdaade2bfaea50ccdac5897f6003ddbd8ffb6dd61 (diff)
downloadzsh-fdae219903892548d9a8facfdd20d989bc24870e.tar.gz
zsh-fdae219903892548d9a8facfdd20d989bc24870e.tar.xz
zsh-fdae219903892548d9a8facfdd20d989bc24870e.zip
offer multiuser screen sessions for attaching/detaching
Diffstat (limited to 'Completion/Unix')
-rw-r--r--Completion/Unix/Command/_screen10
1 files changed, 5 insertions, 5 deletions
diff --git a/Completion/Unix/Command/_screen b/Completion/Unix/Command/_screen
index a744fa72b..bb2153160 100644
--- a/Completion/Unix/Command/_screen
+++ b/Completion/Unix/Command/_screen
@@ -76,18 +76,18 @@ if [[ -n $state ]]; then
   case $state in
     attached-sessions)
       sessions=(
-	${${${${(f)"$(_call_program screen-sessions $words[1] \
-            -ls)"}[2,-3]##[[:blank:]]}:#*Detached*}%[[:blank:]]*}
+        ${${${(M)${(f)"$(_call_program screen-sessions $words[1] \
+            -ls)"}:#*[Aa]ttached*}##[[:blank:]]}%%[[:blank:]]*}
       )
     ;;
     detached-sessions)
       sessions=(
-	${${${${(f)"$(_call_program screen-sessions $words[1] \
-            -ls)"}[2,-3]##[[:blank:]]}:#*Attached*}%[[:blank:]]*}
+        ${${${(M)${(f)"$(_call_program screen-sessions $words[1] \
+            -ls)"}:#*[Dd]etached*}##[[:blank:]]}%%[[:blank:]]*}
       )
     ;;
   esac
-  
+
   # check if initial PID is necessary to make sessions unambiguous
   if [[ ${#${(u)sessions#*.}} -lt $#sessions ]]; then
     _wanted screen-sessions expl "${state%-*} screen process" \