Fix zshenv

This commit is contained in:
Ivan Malison 2014-08-19 09:27:13 -07:00
parent 043e327118
commit f00b469e42

View File

@ -1,4 +1,4 @@
# ssh, scp, ping, host 0;95;c# ssh, scp, ping, host
zstyle ':completion:*:scp:*' tag-order \ zstyle ':completion:*:scp:*' tag-order \
'hosts:-host hosts:-domain:domain hosts:-ipaddr:IP\ address *' 'hosts:-host hosts:-domain:domain hosts:-ipaddr:IP\ address *'
zstyle ':completion:*:scp:*' group-order \ zstyle ':completion:*:scp:*' group-order \
@ -16,7 +16,6 @@ zstyle ':completion:*:(ssh|scp):*:hosts-ipaddr' ignored-patterns \
'^<->.<->.<->.<->' '127.0.0.<->' '^<->.<->.<->.<->' '127.0.0.<->'
zstyle ':completion:*:(ssh|scp):*:users' ignored-patterns \ zstyle ':completion:*:(ssh|scp):*:users' ignored-patterns \
adm bin daemon halt lp named shutdown sync adm bin daemon halt lp named shutdown sync
If you also want tab completion of the hosts listed in your ~/.ssh/known_hosts and /etc/hosts files, you can add:
zstyle -e ':completion:*:(ssh|scp):*' hosts 'reply=( zstyle -e ':completion:*:(ssh|scp):*' hosts 'reply=(
${=${${(f)"$(cat {/etc/ssh_,~/.ssh/known_}hosts(|2)(N) \ ${=${${(f)"$(cat {/etc/ssh_,~/.ssh/known_}hosts(|2)(N) \