[Bash-completion-commits] ./current r1147: Trying to fix a hard-to-catch bug

David Paleino d.paleino at gmail.com
Mon Jun 23 11:34:05 UTC 2008


------------------------------------------------------------
revno: 1147
committer: David Paleino <d.paleino at gmail.com>
branch nick: current
timestamp: Mon 2008-06-23 13:34:05 +0200
message:
  Trying to fix a hard-to-catch bug
modified:
  bash_completion
-------------- next part --------------
=== modified file 'bash_completion'
--- a/bash_completion	2008-06-23 10:03:06 +0000
+++ b/bash_completion	2008-06-23 11:34:05 +0000
@@ -23,7 +23,7 @@
 #
 #   http://bash-completion.alioth.debian.org/
 #
-#   RELEASE: 20080617.2
+#   RELEASE: 20080617.3
 
 if [[ $- == *v* ]]; then
 	BASH_COMPLETION_ORIGINAL_V_VALUE="-v"
@@ -3244,7 +3244,7 @@
 			if [[ ${#COMP_WORDS[@]} -ge 2 ]]; then
 				$func $cmd "${COMP_WORDS[${#COMP_WORDS[@]}-1]}" "${COMP_WORDS[${#COMP_WORDS[@]}-2]}"
 			else
-				$func $cmd "${COMP_WORDS[${#COMP_WORDS[@]}-1}}"
+				$func $cmd "${COMP_WORDS[${#COMP_WORDS[@]}-1]}"
 			fi
 
 			# remove any \: generated by a command that doesn't
@@ -9364,16 +9364,17 @@
 	return 0
 }
 complete -F _svnlook $default svnlook
+}
 
+have rrdtool &&
 _rrdtool ()
 {
 	cur=`_get_cword`
 	COMPREPLY=( $( compgen -W 'create update updatev graph dump \
 	                           restore last lastupdate first info \
 	                           fetch tune resize xport' -- $cur ) )
-}
+} &&
 complete -F _rrdtool rrdtool
-}
 
 _filedir_xspec()
 {
@@ -9400,7 +9401,7 @@
 
 	while read -r tmp; do
 		[[ -n $tmp ]] && toks[${#toks[@]}]=$tmp
-	done < <( compgen -f -X $xspec -- "\$(quote_readline "\$cur")" )	
+	done < <( eval compgen -f -X $xspec -- "\$(quote_readline "\$cur")" )	
 	
 	COMPREPLY=( "${toks[@]}" )
 }



More information about the Bash-completion-commits mailing list