diff --git a/zshrc b/zshrc index 87da6c9..85f6761 100644 --- a/zshrc +++ b/zshrc @@ -66,6 +66,8 @@ bashcompinit # first symbol autocomplete zstyle ':completion:*' insert-tab false zstyle ':completion:*' max-errors 2 +# correct host complete +[[ -f ~/.ssh/config ]] && zstyle ':completion:*' hosts $(awk '/^Host .*$/ { print $2 }' ~/.ssh/config) # prompt autoload -U promptinit diff --git a/zshrc_foreing_server b/zshrc_foreing_server index fd42f1c..f601675 100644 --- a/zshrc_foreing_server +++ b/zshrc_foreing_server @@ -21,6 +21,8 @@ bashcompinit # first symbol autocomplete zstyle ':completion:*' insert-tab false zstyle ':completion:*' max-errors 2 +# correct host complete +[[ -f ~/.ssh/config ]] && zstyle ':completion:*' hosts $(awk '/^Host .*$/ { print $2 }' ~/.ssh/config) # prompt autoload -U promptinit diff --git a/zshrc_server b/zshrc_server index 04e5c73..58deca5 100644 --- a/zshrc_server +++ b/zshrc_server @@ -66,6 +66,8 @@ bashcompinit # first symbol autocomplete zstyle ':completion:*' insert-tab false zstyle ':completion:*' max-errors 2 +# correct host complete +[[ -f ~/.ssh/config ]] && zstyle ':completion:*' hosts $(awk '/^Host .*$/ { print $2 }' ~/.ssh/config) # prompt autoload -U promptinit diff --git a/zshrc_t440 b/zshrc_t440 index 52e510d..39c914d 100644 --- a/zshrc_t440 +++ b/zshrc_t440 @@ -66,6 +66,8 @@ bashcompinit # first symbol autocomplete zstyle ':completion:*' insert-tab false zstyle ':completion:*' max-errors 2 +# correct host complete +[[ -f ~/.ssh/config ]] && zstyle ':completion:*' hosts $(awk '/^Host .*$/ { print $2 }' ~/.ssh/config) # prompt autoload -U promptinit