summaryrefslogtreecommitdiff
path: root/Completion
diff options
context:
space:
mode:
Diffstat (limited to 'Completion')
-rw-r--r--Completion/Core/_path_files26
1 files changed, 13 insertions, 13 deletions
diff --git a/Completion/Core/_path_files b/Completion/Core/_path_files
index 10fe39869..31b8dff66 100644
--- a/Completion/Core/_path_files
+++ b/Completion/Core/_path_files
@@ -86,6 +86,19 @@ if (( ! $mopts[(I)-[JVX]] )); then
mopts=( "$mopts[@]" "$expl[@]" )
fi
+# If given no `-F' option, we may want to use $fignore, turned into patterns.
+
+[[ -z "$_comp_no_ignore" && $#ignore -eq 0 &&
+ ( -z $gopt || "$pats" = \ #\*\ # ) && -n $FIGNORE ]] &&
+ ignore=( "?*${^fignore[@]}" )
+
+if (( $#ignore )); then
+ _comp_ignore=( "$_comp_ignore[@]" "$ignore[@]" )
+ (( $mopts[(I)-F] )) || mopts=( "$mopts[@]" -F _comp_ignore )
+fi
+
+(( $#matcher )) && mopts=( "$mopts[@]" "$matcher[@]" )
+
if zstyle -s ":completion:${curcontext}:files" file-sort tmp1; then
case "$tmp1" in
*size*) sort=oL;;
@@ -140,19 +153,6 @@ eorig="$orig"
( -n "$compstate[pattern_match]" &&
"${orig#\~}" != "${${orig#\~}:q}" ) ]] && menu=yes
-# If given no `-F' option, we may want to use $fignore, turned into patterns.
-
-[[ -z "$_comp_no_ignore" && $#ignore -eq 0 &&
- ( -z $gopt || "$pats" = \ #\*\ # ) && -n $FIGNORE ]] &&
- ignore=( "?*${^fignore[@]}" )
-
-if (( $#ignore )); then
- _comp_ignore=( "$_comp_ignore[@]" "$ignore[@]" )
- (( $mopts[(I)-F] )) || mopts=( "$mopts[@]" -F _comp_ignore )
-fi
-
-(( $#matcher )) && mopts=( "$mopts[@]" "$matcher[@]" )
-
# Now let's have a closer look at the string to complete.
if [[ "$pre[1]" = \~ ]]; then