Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: cd completion and CDABLE_VARS



On 2004-03-11 12:28:17 +0000, Peter Stephenson wrote:
> Go to the point where you want completion to be performed and type ^xh.
> You should get something like:
> 
> tags in context :completion::complete:cd::
>     local-directories path-directories named-directories  (_alternative _cd) 
>     users named-directories directory-stack               (_tilde _alternative _cd) 
>     users                                                 (_users _tilde _alternative _cd)
> 
> (I actually typed `cd z^xh' but it shouldn't matter much.)
> 
> Those names on the left of the list are what you want.  You now need to
> tell the completion system what order you want it to show the tags:
> 
> zstyle ':completion:*:complete:cd:*' tag-order \
>   'local-directories path-directories directory-stack' '*'

Thanks.

BTW, in my case, before using the above zstyle, when I did

  cd pri[TAB]

I got:

  princell  private/

where princell isn't a named directory, but a user name (~princell
being his home directory). If user home directories are regarded as
named directories (as ^xh suggests), then what does "users" mean?

> bindkey "^X^N" _next_tags

I have the same problem as Stefan. I don't get the matches for the
next set of tags with it.

Concerning the keys, I also suggest "^[[Z", which corresponds to
shift-tab here.

-- 
Vincent Lefèvre <vincent@xxxxxxxxxx> - Web: <http://www.vinc17.org/> - 100%
validated (X)HTML - Acorn Risc PC, Yellow Pig 17, Championnat International
des Jeux Mathématiques et Logiques, TETRHEX, etc.
Work: CR INRIA - computer arithmetic / SPACES project at LORIA



Messages sorted by: Reverse Date, Date, Thread, Author