[Bash-completion-commits] [SCM] bash-completion branch, master, updated. 2.1-11-gdaaa541

Ville Skyttä ville.skytta at iki.fi
Fri May 3 13:50:24 UTC 2013


The following commit has been merged in the master branch:
commit daaa54100ed061a0c8e7ce89a8bda009530246a3
Author: Ville Skyttä <ville.skytta at iki.fi>
Date:   Fri May 3 16:49:25 2013 +0300

    sh: Complete script arguments with all filenames (Alioth: #314226).

diff --git a/completions/sh b/completions/sh
index b70e53e..4b66f84 100644
--- a/completions/sh
+++ b/completions/sh
@@ -26,7 +26,10 @@ _sh()
         return 0
     fi
 
-    _filedir sh
+    local args ext=
+    _count_args
+    [[ $args -eq 1 ]] && ext=sh
+    _filedir $ext
 } &&
 complete -F _sh sh
 

-- 
bash-completion



More information about the Bash-completion-commits mailing list