From fea3997153ef2388eb4bb31d5a27065956f4b9ed Mon Sep 17 00:00:00 2001 From: Omer Tuchfeld Date: Thu, 5 Nov 2020 00:04:48 +0200 Subject: [PATCH] '.' no longer special, '..' only sometimes --- lib/completion.zsh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) 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'