mirror of
https://github.com/timescale/timescaledb.git
synced 2025-05-17 02:53:51 +08:00
15 lines
288 B
Bash
Executable File
15 lines
288 B
Bash
Executable File
#!/bin/bash
|
|
|
|
# To avoid pw writing, add localhost:5432:*:postgres:test to ~/.pgpass
|
|
set -u
|
|
set -e
|
|
|
|
PWD=`pwd`
|
|
DIR=`dirname $0`
|
|
|
|
export PGUSER=${PGUSER:-postgres}
|
|
export PGHOST=${PGHOST:-localhost}
|
|
export PGDATABASE=${PGDATABASE:-timescaledb}
|
|
|
|
psql -v ON_ERROR_STOP=1 -q -X -f $DIR/sql/$1
|