-
Notifications
You must be signed in to change notification settings - Fork 1
/
psqlrc
36 lines (27 loc) · 880 Bytes
/
psqlrc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
-- PostgreSQL CLI client configuration
-- Adapted from https://github.com/eevee/rc/blob/master/.psqlrc
-- No echo when applying commands from config
\set QUIET on
-- Display how long each statement took
\timing on
-- Automatically undo on error when in interactive mode
\set ON_ERROR_ROLLBACK interactive
-- More verbose error descriptions
\set VERBOSITY verbose
-- Prompt 1: Normal prompt
\set PROMPT1 '%[%033[0;33m%]%n@%M%[%033[0m%]/%[%033[0;1;32m%]%/%R%[%033[0m%] ⚒ '
-- Prompt 2: Continuation
\set PROMPT2 '%[%033[1;30m%]...%[%033[0m%] %R '
-- History file
\set HISTFILE ~/.psql_history- :DBNAME
-- History behaviour
\set HISTCONTROL ignoredups
-- Complete SQL keywords in uppercase
\set COMP_KEYWORD_CASE upper
-- Draw tables with unicode symbols
\pset linestyle unicode
-- NULL value indicator
\pset null ␀
-- Turn on echo again
\unset QUIET
-- vim:set ft=sql: