about summary refs log tree commit diff
path: root/Completion/Core/_path_files
diff options
context:
space:
mode:
authorTanaka Akira <akr@users.sourceforge.net>1999-12-13 14:06:30 +0000
committerTanaka Akira <akr@users.sourceforge.net>1999-12-13 14:06:30 +0000
commitdcc6d87c9fd16fa868fe2dffffbf724b7ae71511 (patch)
tree19e4358cd2965f87f477e39502748a606faf194d /Completion/Core/_path_files
parenta5f7a6272d0c834cf315dced8ce93ecac3f3a295 (diff)
downloadzsh-dcc6d87c9fd16fa868fe2dffffbf724b7ae71511.tar.gz
zsh-dcc6d87c9fd16fa868fe2dffffbf724b7ae71511.tar.xz
zsh-dcc6d87c9fd16fa868fe2dffffbf724b7ae71511.zip
zsh-workers/9020
Diffstat (limited to 'Completion/Core/_path_files')
-rw-r--r--Completion/Core/_path_files15
1 files changed, 11 insertions, 4 deletions
diff --git a/Completion/Core/_path_files b/Completion/Core/_path_files
index 993d0e89a..cafec3c09 100644
--- a/Completion/Core/_path_files
+++ b/Completion/Core/_path_files
@@ -224,12 +224,19 @@ for prepath in "$prepaths[@]"; do
 
     if [[ "$tpre$tsuf" = */* ]]; then
       tmp2=( ${^tmp1}*(-/) )
-      [[ ! -o globdots && "$PREFIX" = .* ]] &&
-          tmp2=( "$tmp2[@]" ${^tmp1}.*(-/) . .. )
+      if [[ ! -o globdots && "$PREFIX" = .* ]]; then
+        tmp2=( "$tmp2[@]" ${^tmp1}.*(-/) )
+	zstyle -t ":completion${curcontext}:paths" special-dirs &&
+	    tmp2=( "$tmp2[@]" . .. )
+      fi
     else
       tmp2=( ${^tmp1}${^~pats} )
-      [[ ! -o globdots && "$PREFIX" = .* ]] &&
-          tmp2=( "$tmp2[@]" ${^tmp1}.${^~pats} . .. )
+      if [[ ! -o globdots && "$PREFIX" = .* ]]; then
+        tmp2=( "$tmp2[@]" ${^tmp1}.${^~pats} )
+        [[ "$sopt" = */* ]] &&
+	    zstyle -t ":completion${curcontext}:paths" special-dirs &&
+	    tmp2=( "$tmp2[@]" . .. )
+      fi
     fi
     tmp1=( "$tmp2[@]" )