Skip to content

Commit

Permalink
nix: Show connection hints for postgrest-with-postgresql-xx on stdout
Browse files Browse the repository at this point in the history
This allows running this together with postgrest-run --dump-schema and
piping the result into jq without syntax errors.
  • Loading branch information
wolfgangwalther committed Feb 19, 2024
1 parent 8ff9f32 commit 4a796e0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions nix/tools/withTools.nix
Original file line number Diff line number Diff line change
Expand Up @@ -89,8 +89,8 @@ let
log "Creating a minimally privileged $PGUSER connection role..."
createuser "$PGUSER" -U postgres --host="$tmpdir/socket" --no-createdb --no-inherit --no-superuser --no-createrole --no-replication --login
echo "${commandName}: You can connect with: psql 'postgres:///$PGDATABASE?host=$tmpdir/socket' -U postgres"
echo "${commandName}: You can tail the logs with: tail -f $tmpdir/db.log"
>&2 echo "${commandName}: You can connect with: psql 'postgres:///$PGDATABASE?host=$tmpdir/socket' -U postgres"
>&2 echo "${commandName}: You can tail the logs with: tail -f $tmpdir/db.log"
fi
if test "$_arg_fixtures"; then
Expand Down

0 comments on commit 4a796e0

Please sign in to comment.