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

autocompletion with ssh and .ssh/config



Hi,

I have some hosts defined in my .ssh/config file. Example :
Host bar
    HostName 1.2.3.4

Host baz
    HostName 2.3.4.5

When I type ssh <tab>, only my users and hosts in /etc/hosts are displayed
(my .ssh/config is ignored).
With ssh ba<tab> the autocompletion is correctly done and propose bar and
baz.
Same behavior with ssh user@<tab> and ssh user@ba<tab>

Expected : Hosts from ssh/config are proposed by the autocompletion with the
other hosts.

I did some research and the root of the problem seems to be in
Completion/Unix/Command/_ssh, function _ssh_hosts : the function exists too
early (before reading ssh/config).


Used .zshrc :
autoload -U compinit
compinit

Tested env : zsh 4.3.10 and 4.3.10-dev-1, OS : Archlinux.


Thanks
David Duponchel


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