Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Issue with insert-sections style
- X-seq: zsh-workers 28245
- From: Julius Plenz <julius@xxxxxxxxx>
- To: zsh-workers@xxxxxxx
- Subject: Issue with insert-sections style
- Date: Thu, 9 Sep 2010 16:50:15 +0200
- List-help: <mailto:zsh-workers-help@zsh.org>
- List-id: Zsh Workers List <zsh-workers.zsh.org>
- List-post: <mailto:zsh-workers@zsh.org>
- Mail-followup-to: zsh-workers@xxxxxxx
- Mailing-list: contact zsh-workers-help@xxxxxxx; run by ezmlm
Hi there,
I discovered an issue with the insert-sections style for manual
pages (which, by the way, is not documented anywhere).
If you use the _oldlist completer together with the no_list_ambiguous
option the following bug occurs: When you have entered a man page name
with a prefix that can only be expanded to man pages from one section,
that section number gets inserted when drawing the listing, and then
*again* when the user enters menu completion.
Provided below is a minimal zshrc to reproduce the bug. An example
which will work on most systems might be "man pam_li<Tab><Tab>":
# minimal setup
autoload -U compinit && compinit
zmodload -i zsh/complist
bindkey '^i' complete-word
zstyle ':completion:*' menu select # if you like
zstyle ':completion:*' group-name ''
zstyle ':completion:*:descriptions' format 'completing %B%d%b'
zstyle ':completion:*:manuals' separate-sections true
# make insertion possible
setopt extendedglob
zstyle ':completion:*:manuals.(^1*)' insert-sections true
# cause double-insertion
zstyle ':completion:*' completer _oldlist _complete
setopt nolistambiguous
Cheers,
Julius
Messages sorted by:
Reverse Date,
Date,
Thread,
Author