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

Ville Skyttä ville.skytta at iki.fi
Sun May 10 17:27:48 UTC 2009


The following commit has been merged in the master branch:
commit 3e016e4679de7fda6114ee00ddcaac79f1998893
Author: Ville Skyttä <ville.skytta at iki.fi>
Date:   Sun May 10 20:22:45 2009 +0300

    Use compgen -W in postgresql databases completion (still disabled though).

diff --git a/bash_completion b/bash_completion
index 2a0ed7f..1b2a566 100644
--- a/bash_completion
+++ b/bash_completion
@@ -4131,10 +4131,10 @@ complete -F _gdb $default gdb
 have psql && {
 _pg_databases()
 {
-	return
-	COMPREPLY=( $( psql -l 2>/dev/null | \
+	return # intentionally disabled in 7ebed6af (TODO: why?)
+	COMPREPLY=( $( compgen -W "$( psql -l 2>/dev/null | \
 			sed -e '1,/^-/d' -e '/^(/,$d' | \
-			awk '{print $1}' | grep "^$cur" ) )
+			awk '{print $1}' )" -- $cur ) )
 }
 
 _pg_users()

-- 
bash-completion



More information about the Bash-completion-commits mailing list