diff --git a/lib/completion.zsh b/lib/completion.zsh index 2b62785d5..b11bbe20f 100644 --- a/lib/completion.zsh +++ b/lib/completion.zsh @@ -25,8 +25,8 @@ else fi unset CASE_SENSITIVE HYPHEN_INSENSITIVE -# Complete . and .. special directories -zstyle ':completion:*' special-dirs true +# Only treat .. as a special directory when the prefix is empty, '.' or '../' +zstyle -e ':completion:*' special-dirs '[[ $PREFIX = (../)#(|.|..) ]] && reply=(..)' zstyle ':completion:*' list-colors '' zstyle ':completion:*:*:kill:*:processes' list-colors '=(#b) #([0-9]#) ([0-9a-z-]#)*=01;34=0=01'