Re: get rid of psql welcome message - Mailing list pgsql-hackers

From Shane Ambler
Subject Re: get rid of psql welcome message
Date
Msg-id 480CD622.9030005@Sheeky.Biz
Whole thread Raw
In response to Re: get rid of psql welcome message  ("Joshua D. Drake" <jd@commandprompt.com>)
Responses Re: get rid of psql welcome message  (Peter Eisentraut <peter_e@gmx.net>)
List pgsql-hackers
This idea may be taking it to the extreme but I thought I'd throw it out
there anyway as everyone seems to want something different. (well there
seems to be three variants that if all were available would keep most
people happy) This may be one way to please everyone.



What if the actual welcome message can be defined in the .psqlrc ?
Something along the lines of -

WELCOME_MESSAGE="Welcome to <VERS_PSQL> - <VERS_SERVER>\n<SSL_INFO>"

(or similar with tags available that will allow predefined info to be
inserted)

I also see with this path that there could be a configure option to
specify the default welcome text, I am thinking three options would keep
most happy without adjustment in .psqlrc

--default-welcome-message=[classic|short|oneline|"custom string"]

"custom string" would match the above setting options - classic would be
the default.


This could also give the option in .psqlrc of having -

WELCOME_MESSAGE=<CLASSIC>

From there you can customise the setting to what you want and even
across all machines in the office to match company policy (so to speak)
setting default .psqlrc file for new users etc.

Along that line maybe implement a way to have default welcome message
settings per server? psql retrieves the welcome settings upon server
connection. (as in psql requests it after connection - not returned with
the initial connection request) This would be the default that is
overridden by the local .psqlrc file.


-- 

Shane Ambler
pgSQL (at) Sheeky (dot) Biz

Get Sheeky @ http://Sheeky.Biz


pgsql-hackers by date:

Previous
From: Bruce Momjian
Date:
Subject: Re: typedefs for indent
Next
From: Andrew Dunstan
Date:
Subject: Re: typedefs for indent