From 640a840d2e94f0fc245ef8632050c37af23c6b94 Mon Sep 17 00:00:00 2001 From: Tanaka Akira Date: Thu, 15 Apr 1999 18:21:49 +0000 Subject: zsh-3.1.5-pws-13 --- Completion/Core/_path_files | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'Completion/Core/_path_files') diff --git a/Completion/Core/_path_files b/Completion/Core/_path_files index 535ba537c..4c61ac7ef 100644 --- a/Completion/Core/_path_files +++ b/Completion/Core/_path_files @@ -111,7 +111,7 @@ orig="${PREFIX}${SUFFIX}" [[ $compstate[insert] = *menu || -n "$_comp_correct" || ( $#compstate[pattern_match] -ne 0 && - "$orig" != "${orig:q}" ) ]] && menu=yes + "${orig#\~}" != "${${orig#\~}:q}" ) ]] && menu=yes # We will first try normal completion called with `compgen', but only if we @@ -405,6 +405,7 @@ for prepath in "$prepaths[@]"; do # No match, insert the expanded path and add the original tail. [[ "$testpath[-1]" = / ]] && testpath="$testpath[1,-2]" + [[ -z "$testpath" && "$linepath[-1]" = / ]] && linepath="$linepath[1,-2]" [[ -n "$ostr" && -n "$linepath$testpath" ]] && ostr="/$ostr" # But only if something changed. -- cgit 1.4.1