Re: small windows psqlrc re-wording

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: small windows psqlrc re-wording
Дата
Msg-id 3972135.1662649369@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: small windows psqlrc re-wording  (Julien Rouhaud <rjuju123@gmail.com>)
Ответы Re: small windows psqlrc re-wording  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
Julien Rouhaud <rjuju123@gmail.com> writes:
> On Wed, Sep 07, 2022 at 01:10:11PM -0400, Tom Lane wrote:
> -     for example <filename>~/.psqlrc-9.2</filename> or
> -     <filename>~/.psqlrc-9.2.5</filename>.  The most specific
> +     for example <filename>~/.psqlrc-15</filename> or
> +     <filename>~/.psqlrc-15.2</filename>.  The most specific

> This bit is a bit saddening.  It's probably good to switch to the new 2 digits
> versioning but not trying to maintain it any further right?

It occurred to me later to substitute &majorversion; and &version;
like this:

+     for example <filename>~/.psqlrc-&majorversion;</filename> or
+     <filename>~/.psqlrc-&version;</filename>.  The most specific

On testing that in HEAD, I read

    Both the system-wide startup file and the user's personal startup file
    can be made psql-version-specific by appending a dash and the
    PostgreSQL major or minor release number to the file name, for example
    ~/.psqlrc-16 or ~/.psqlrc-16devel.

That's a little confusing but it's actually accurate, because what
process_psqlrc_file appends is the string PG_VERSION, so in a devel
branch or beta release there's a non-numeric "minor release".
I'm inclined to go ahead and do it like that.

            regards, tom lane



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Ashutosh Sharma
Дата:
Сообщение: Re: confirmed_flush_lsn shows LSN of the data that has not yet been received by the logical subscriber.
Следующее
От: Pavel Stehule
Дата:
Сообщение: Re: proposal: possibility to read dumped table's name from file