9 lines
313 B
Bash
9 lines
313 B
Bash
autoload -Uz compinit && compinit
|
|
|
|
# Add tab completion for SSH hostnames based on ~/.ssh/config, ignoring wildcards
|
|
if [ -e "$HOME/.ssh/config" ]; then
|
|
zstyle -e ':completion::*:*:*:hosts' hosts 'reply=(${=${${(f)"$(cat {/etc/ssh_,~/.ssh/known_}hosts(|2)(N) /dev/null)"}%%[# ]*}//,/ })'
|
|
fi
|
|
|
|
# vim:set ft=zsh:
|