zsh-workers
 help / color / mirror / code / Atom feed
* PATCH: fix style insert-ids=single
@ 2009-01-28  4:49 Greg Klanderman
  0 siblings, 0 replies; only message in thread
From: Greg Klanderman @ 2009-01-28  4:49 UTC (permalink / raw)
  To: Zsh list

[-- Attachment #1: message body text --]
[-- Type: text/plain, Size: 452 bytes --]


Hi,

As I reported a few days ago, when completing pids with the style
setting insert-ids=single, it is not possible to enter menu completion
via the menu-complete/menu-select key bindings.  This patch fixes this
specific problem, though I cannot claim to understand all the values
that $compstate[insert] can take on well enough to know that there are
not other desirable state transitions still being prevented by this
style setting.

thanks,
Greg


[-- Attachment #2: zsh-pids.patch --]
[-- Type: text/plain, Size: 706 bytes --]

Index: Completion/Unix/Type/_pids
===================================================================
RCS file: /cvsroot/zsh/zsh/Completion/Unix/Type/_pids,v
retrieving revision 1.3
diff -u -r1.3 _pids
--- Completion/Unix/Type/_pids	8 Jun 2005 12:45:36 -0000	1.3
+++ Completion/Unix/Type/_pids	28 Jan 2009 04:26:16 -0000
@@ -45,7 +45,8 @@
 
   case "$out" in
   menu)   compstate[insert]=menu ;;
-  single) [[ $compstate[nmatches] -ne nm+1 ]] && compstate[insert]= ;;
+  single) [[ $compstate[nmatches] -ne nm+1 && $compstate[insert] != menu ]] &&
+              compstate[insert]= ;;
   *)      [[ ${#:-$PREFIX$SUFFIX} -gt ${#compstate[unambiguous]} ]] &&
               compstate[insert]=menu ;;
   esac

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2009-01-28  4:50 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-01-28  4:49 PATCH: fix style insert-ids=single Greg Klanderman

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).