psql: Add variable SERVICEFILE This new psql variable can be used to check which service file has been used for a connection. Like other variables, this can be set in a PROMPT or reported by an \echo, like these commands: \echo :SERVICEFILE \set PROMPT1 '=(%:SERVICEFILE:)%# '
This relies on commits 092f3c63efc6 and fef6da9e9c87 to retrieve this information from the connection's PQconninfoOption. Author: Ryo Kanbayashi <kanbayashi....@gmail.com> Discussion: https://postgr.es/m/cakkg4_ncjx3a_f3gyxhspwxd8sd8uram89wey7fg_9g7kbk...@mail.gmail.com Branch ------ master Details ------- https://git.postgresql.org/pg/commitdiff/6b1c4d326b064bf0eaedccb08a7fcca5db5d9629 Modified Files -------------- doc/src/sgml/ref/psql-ref.sgml | 9 +++++++++ src/bin/psql/command.c | 7 +++++++ 2 files changed, 16 insertions(+)