[Bash-completion-commits] [SCM] bash-completion branch, master, updated. 9f49a101174911d8672c55cdc379ac5a3db186ff

Ville Skyttä ville.skytta at iki.fi
Sat Jan 9 10:57:59 UTC 2010


The following commit has been merged in the master branch:
commit 89affc872b1f345e26a24f7debb95c843ff44fae
Author: Ville Skyttä <ville.skytta at iki.fi>
Date:   Sat Jan 9 11:33:38 2010 +0200

    More sed \? -> \{0,1\} portability fixes.

diff --git a/contrib/mplayer b/contrib/mplayer
index a30dae6..1dd5010 100644
--- a/contrib/mplayer
+++ b/contrib/mplayer
@@ -234,7 +234,7 @@ _mplayer()
             COMPREPLY=( $( compgen -W '$( $cmd -list-options 2>/dev/null | \
                 sed -ne '1,/^[[:space:]]*Name/d' \
                     -e "s/^[[:space:]]*/-/" -e "s/[[:space:]:].*//" \
-                    -e "/^-\(Total\|.*\*\)\?$/!p" )' -- "$cur" ) )
+                    -e "/^-\(Total\|.*\*\)\{0,1\}$/!p" )' -- "$cur" ) )
             ;;
         *)
             _filedir '@(mp?(e)g|MP?(E)G|wm[av]|WM[AV]|avi|AVI|asf|ASF|vob|VOB|bin|BIN|dat|DAT|vcd|VCD|ps|PS|pes|PES|fl[iv]|FL[IV]|viv|VIV|rm?(j)|RM?(J)|ra?(m)|RA?(M)|yuv|YUV|mov|MOV|qt|QT|mp[234]|MP[234]|m4[av]|M4[AV]|og[gmavx]|OG[GMAVX]|w?(a)v|W?(A)V|dump|DUMP|mk[av]|MK[AV]|m4a|M4A|aac|AAC|m[24]v|M[24]V|dv|DV|rmvb|RMVB|mid|MID|ts|TS|3g[p2]|mpc|MPC|flac|FLAC|vro|VRO|divx|DIVX|aif?(f)|AIF?(F)|m2ts|M2TS|vdr|VDR|xvid|XVID|ape|APE)'
diff --git a/contrib/rpm b/contrib/rpm
index f39e76d..525da45 100644
--- a/contrib/rpm
+++ b/contrib/rpm
@@ -97,7 +97,7 @@ _rpm()
         --eval|-E)
             # get a list of macros
             COMPREPLY=( $( rpm --showrc | sed -ne \
-                's/^-\?[0-9]\{1,\}[:=][[:space:]]\{1,\}\('${cur#%}'[^[:space:](]*\).*/\1/p' ) )
+                's/^-\{0,1\}[0-9]\{1,\}[:=][[:space:]]\{1,\}\('${cur#%}'[^[:space:](]*\).*/\1/p' ) )
             COMPREPLY=( "${COMPREPLY[@]/#/%}" )
             return 0
             ;;

-- 
bash-completion



More information about the Bash-completion-commits mailing list