Re: [psql] Setting the PROMPT on command line - Mailing list pgsql-patches

From Neil Conway
Subject Re: [psql] Setting the PROMPT on command line
Date
Msg-id 1097120473.13817.6.camel@localhost.localdomain
Whole thread Raw
In response to Re: [psql] Setting the PROMPT on command line  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: [psql] Setting the PROMPT on command line
List pgsql-patches
On Thu, 2004-10-07 at 13:05, Tom Lane wrote:
> I'm just wondering if the fix is in the right place.  Doesn't the same
> issue arise for other variables?

Well, we don't manually set other variables in psql itself, with the
exception of defining some default values before we process command-line
args or psqlrc (see startup.c circa line 141) -- so in that case
allowing the value to be overriden is fine.

On looking at the code closer though, I do see one related problem: we
process command-line args before we read psqlrc, so psqlrc settings can
override what was specified on the command-line. Shouldn't this happen
in reverse?

-Neil



pgsql-patches by date:

Previous
From: Tom Lane
Date:
Subject: Re: [psql] Setting the PROMPT on command line
Next
From: Tom Lane
Date:
Subject: Re: [psql] Setting the PROMPT on command line