[Bash-completion-commits] [SCM] bash-completion branch, master, updated. 1.90-109-ge6bef77

Igor Murzov e-mail at date.by
Tue Dec 20 21:07:36 UTC 2011


The following commit has been merged in the master branch:
commit e6bef775a5d3ff44c646d0929776d85121ed0554
Author: Igor Murzov <e-mail at date.by>
Date:   Wed Dec 21 01:03:21 2011 +0400

    gcc: Don't use \t in sed as it's not POSIX compliant.

diff --git a/completions/gcc b/completions/gcc
index 9dc21c7..c86fd7e 100644
--- a/completions/gcc
+++ b/completions/gcc
@@ -38,9 +38,8 @@ _gcc()
         # sink stderr:
         # for C/C++/ObjectiveC it's useless
         # for FORTRAN/Java it's an error
-        COMPREPLY=( $( compgen -W "$( $cc --help 2>/dev/null | \
-           sed -e 's/\t/ /g' -e '/^  *-/!d' -e 's/ *-\([^][ <>]*\).*/-\1/' )" \
-           -- "$cur" ) )
+        COMPREPLY=( $( compgen -W "$( $cc --help 2>/dev/null | tr '\t' ' ' |\
+           sed -e '/^  *-/!d' -e 's/ *-\([^][ <>]*\).*/-\1/' )" -- "$cur" ) )
         [[ $COMPREPLY == *= ]] && compopt -o nospace
     else
         _filedir

-- 
bash-completion



More information about the Bash-completion-commits mailing list