Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
completion: matcher(-list) and tags
- X-seq: zsh-users 15196
- From: RogutÄs Sparnuotos <rogutes@xxxxxxxxxxxxxx>
- To: zsh-users@xxxxxxx
- Subject: completion: matcher(-list) and tags
- Date: Thu, 22 Jul 2010 03:55:58 +0300
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=gamma; h=domainkey-signature:received:received:date:from:to:subject :message-id:mime-version:content-type:content-disposition :content-transfer-encoding; bh=EApkOfE18s/txwu6RwBSZqTlQldFQEXFfjDW7IJp8GY=; b=Qm++27S/Odn0yh5s1wfDg17rRJK0aYkboceUhho3PQUJWuJ5FlG5Y65CSsFGRvm4LZ JZZOtbi/ShzlWFNkmzp8M/QLjiZUFt1w7w9TD5m5RLjwcjWcsOGsQ1V/2q/aXa7IKIWH 3o7cV/8zkBn3ZW9kLQiZGgamxAJt90kSmtGoQ=
- Domainkey-signature: a=rsa-sha1; c=nofws; d=googlemail.com; s=gamma; h=date:from:to:subject:message-id:mime-version:content-type :content-disposition:content-transfer-encoding; b=Ob8CRYeEHeLDlB0OtsB+9gjau5ye7uwgXLvAUXOVGZRVRWKCf/dN8e3MIe3mfzlWbS KuKwNzliJyBybZuQfmOwQ6SAqLiWudcIzdY2sJPlE3TTvaiNR7EVIWxsxHu/Zujx9H2+ lEXcwd7SwXKtG4tBzNl1CDsapEM0cIi+4bmJ8=
- List-help: <mailto:zsh-users-help@zsh.org>
- List-id: Zsh Users List <zsh-users.zsh.org>
- List-post: <mailto:zsh-users@zsh.org>
- Mailing-list: contact zsh-users-help@xxxxxxx; run by ezmlm
G'day,
I am trying to get this to work:
zstyle ':completion:*:all-files' matcher-list '' \
'm:{[:lower:]}={[:upper:]}' '+e:=*' '+b:=*'
because I do not need the matcher-list to apply for all tags (and it is
too slow with slower machines). But the zstyle does not work.
Looking through zshcompsys(1), I find a paragraph under the tag-order
explanation, saying that matcher-list "is tested very early in the
completion system and hence can't be set for single commands nor for more
specific contexts" (but if so, shouldn't such matcher-list usage exit with
an error?). So I try to adapt a tag-order + matcher example to test things
out:
zsh --no-rcs
autoload -Uz compinit; compinit
zstyle ':completion:*' format '=== %d ==='
zstyle ':completion:*' tag-order '*:-case:XXX'
zstyle ':completion:*:*-case' matcher 'm:{a-z}={A-Z}'
And it seems to work for commands, but not for files... What am I doing
wrong (zsh-4.3.10)?
----
Below is a snippet from a testing run with the above zstyles (ran from
/usr/bin, with it being in path and containing the Xorg binary):
1. 'ls<TAB>' shows '=== XXX ==='
2. 'ls <TAB>' shows '=== XXX ==='
3. 'ls xorg<TAB>' prints '=== `files' or `XXX' ==='
4. 'xorg<TAB>' completes to 'Xorg'
5. './xorg<TAB>' prints
=== `external command', `XXX', `executable file or directory', `builtin
command', `shell function', `alias', `suffix alias', `reserved word',
`job', or `parameter' ===
--
-- RogutÄs Sparnuotos
Messages sorted by:
Reverse Date,
Date,
Thread,
Author