Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

PATCH: match uppercase file extensions for zathura



Unlike _pspdf, zathura's completion is matching only lowercase file
extensions. I happened to get a file in an e-mail where the extension
was uppercase - .PDF. So this changes the completion to handle that.

Oliver

diff --git a/Completion/X/Command/_zathura b/Completion/X/Command/_zathura
index 615488068..ebd229909 100644
--- a/Completion/X/Command/_zathura
+++ b/Completion/X/Command/_zathura
@@ -11,7 +11,7 @@ _zathura_files(){
     plugins_files+=( $plugins_dir/*.so(N) )
   done
   if [[ -z "${plugins_files}" ]]; then
-    _files -g "*.pdf(-.)"
+    _files -g "(#i)*.pdf(-.)"
     return
   fi
   local -a supported_filetypes
@@ -27,7 +27,7 @@ _zathura_files(){
       supported_filetypes+="${pf:t:r}"
     fi
   done
-  _files -g "*.(${(j.|.)${(@u)supported_filetypes}})(-.)"
+  _files -g "(#i)*.(${(j.|.)${(@u)supported_filetypes}})(-.)"
 }
 
 _arguments -s -S \



Messages sorted by: Reverse Date, Date, Thread, Author