summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Palfrader <peter@palfrader.org>2011-05-02 15:16:52 +0000
committerweasel <weasel@bc3d92e2-beff-0310-a7cd-cc87d7ac0ede>2011-05-02 15:16:52 +0000
commit53da07ad6ff2ee1880fa53bcdf00fc18c923665b (patch)
tree014999ddefe9e587360f49039fae527ff4d06146
parenta442d694fb1dc61e4aafab9b0321e5fef42f1760 (diff)
Handle continuation lines in psql -l output
git-svn-id: svn+ssh://asteria.noreply.org/svn/weaselutils/trunk@479 bc3d92e2-beff-0310-a7cd-cc87d7ac0ede
-rwxr-xr-xbackup-pg2
1 files changed, 1 insertions, 1 deletions
diff --git a/backup-pg b/backup-pg
index 79274c2..671afc5 100755
--- a/backup-pg
+++ b/backup-pg
@@ -64,7 +64,7 @@ else
exit 1
fi
-$SUDO psql $PORT -l -t | awk '$1 != "" {print $1}' |
+$SUDO psql $PORT --list --tuples-only | grep -v '^.*:' | awk '$1 != "" {print $1}' |
while read db; do
if [ "$db" = "template0" -o "$db" = "template1" ] ; then
continue;