From: Bruce Momjian Date: Mon, 17 Dec 2007 09:03:52 +0000 (+0000) Subject: Update archive_command example to use || test, rather than if []. X-Git-Url: http://git.postgresql.org/gitweb/static/gitweb.js?a=commitdiff_plain;h=1b089b949690ca761f4f04f34d6debcc798da4d5;p=users%2Fbernd%2Fpostgres.git Update archive_command example to use || test, rather than if []. --- diff --git a/doc/src/sgml/backup.sgml b/doc/src/sgml/backup.sgml index b2bba256f4..a9722c3d38 100644 --- a/doc/src/sgml/backup.sgml +++ b/doc/src/sgml/backup.sgml @@ -1290,7 +1290,7 @@ restore_command = 'copy /mnt/server/archivedir/%f "%p"' # Windows on, and set up an archive_command that performs archiving only when a switch file exists. For example: -archive_command = 'if [ -f /var/lib/pgsql/backup_in_progress ]; then cp -i %p /var/lib/pgsql/archive/%f </dev/null ; fi' +archive_command = 'test ! -f /var/lib/pgsql/backup_in_progress || cp -i %p /var/lib/pgsql/archive/%f < /dev/null' This command will perform archiving when /var/lib/pgsql/backup_in_progress exists, and otherwise