Code

pgtest.sh: Added documentation for 'restart'.
[postrr.git] / pgtest.sh
index 3c746295d8e1901973847afd1a8bb1052a5b8503..be58830da8698a5cbff396fb327c79e50e8b583a 100755 (executable)
--- a/pgtest.sh
+++ b/pgtest.sh
@@ -91,6 +91,9 @@ case "$1" in
                        $BIN_DIR/postgres -D $TARGET/var/lib/postgresql/main "$@"
                fi
                ;;
+       restart)
+               $0 stop && $0 start -B
+               ;;
        *)
                echo "Usage: $0 setup|client|stop|start" >&2
                echo ""
@@ -103,6 +106,8 @@ case "$1" in
                echo "    Start the PostgreSQL server."
                echo "  - stop"
                echo "    Stop the PostgreSQL server."
+               echo "  - restart"
+               echo "    Restart a background PostgreSQL server process."
                echo ""
                echo "Environment variables:"
                echo "  - TARGET"