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

Re: tab completion list does not complete dot files



"t takahashi" wrote:
> when i use tab completion on a directory with dot files, the dot files
> are ignored in the completion list.  "/tmp/\t" will not list
> /tmp/.foo.
> 
> in the man pages i have not found a way to make zsh list the dot files
> in the completion list when i press tab.

I assume you are using the "new" completion system (it's not so new now).

You can make the *entire* completion system do this by putting
the following code in your initialisation file after you run "compinit":

_comp_options+=(globdots)

If your version of the shell is before 4.2, you might need to expand that:

_comp_options=($_comp_options globdots)

This will make the completion system complete files beginning with dot
in every single place it possibly could.  I don't think there's an easy
way of restricting the effect.  However, as you wanted, it won't affect
the use of globbing ("*" etc.) on the command line.

-- 
Peter Stephenson <pws@xxxxxxx>                  Software Engineer
CSR PLC, Churchill House, Cambridge Business Park, Cowley Road
Cambridge, CB4 0WZ, UK                          Tel: +44 (0)1223 692070


To access the latest news from CSR copy this link into a web browser:  http://www.csr.com/email_sig.php

To get further information regarding CSR, please visit our Investor Relations page at http://ir.csr.com/csr/about/overview



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