Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commite0636ca

Browse files
committed
Doc: improve documentation about where the psqlrc files are.
Remove no-longer-accurate claim that Windows lacks home directories.Clarify the text by more clearly distinguishing which statementsreflect hard-wired choices versus which ones reflect overridabledefaults. Update the examples of version-specific file names,and make them track future version changes by using "&majorversion;"and "&version;". (BTW, in devel and beta releases this methodcorrectly says that you can use strings like "16devel" and "15beta4"as minor version identifiers.)Back-patch to v15, but not further, with the thought that in olderreleases the examples with three-part version numbers still hadsome historical relevance. v15 will be the first major release afterthe last 9.x branch went out of support.Robert Treat and Tom Lane, reviewed by Julien RouhaudDiscussion:https://postgr.es/m/CAJSLCQ07F-WCYYYOY8+dWhHcVeJ1Pb01cWc-c0Hu=M3EjKT2Eg@mail.gmail.com
1 parent100a8ca commite0636ca

File tree

1 file changed

+17
-13
lines changed

1 file changed

+17
-13
lines changed

‎doc/src/sgml/ref/psql-ref.sgml

Lines changed: 17 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -4859,32 +4859,36 @@ PSQL_EDITOR_LINENUMBER_ARG='--line '
48594859
commands.
48604860
</para>
48614861
<para>
4862-
The system-wide startup file is named <filename>psqlrc</filename> and is
4862+
The system-wide startup file is named <filename>psqlrc</filename>.
4863+
By default it is
48634864
sought in the installation's <quote>system configuration</quote> directory,
48644865
which is most reliably identified by running <literal>pg_config
4865-
--sysconfdir</literal>. By default this directory will be <filename>../etc/</filename>
4866+
--sysconfdir</literal>.
4867+
Typically this directory will be <filename>../etc/</filename>
48664868
relative to the directory containing
4867-
the <productname>PostgreSQL</productname> executables. The name of this
4868-
directory can be set explicitly via the <envar>PGSYSCONFDIR</envar>
4869-
environment variable.
4869+
the <productname>PostgreSQL</productname> executables.
4870+
Thedirectoryto look incan be set explicitly via
4871+
the <envar>PGSYSCONFDIR</envar>environment variable.
48704872
</para>
48714873
<para>
48724874
The user's personal startup file is named <filename>.psqlrc</filename>
4873-
and is sought in the invoking user's home directory. On Windows, which
4874-
lacks such a concept,the personal startup file is named
4875+
and is sought in the invoking user's home directory.
4876+
On Windowsthe personal startup file is instead named
48754877
<filename>%APPDATA%\postgresql\psqlrc.conf</filename>.
4876-
The location of the user's startupfile can beset explicitly via
4878+
In either case, this defaultfilepathcan beoverridden by setting
48774879
the <envar>PSQLRC</envar> environment variable.
48784880
</para>
48794881
<para>
48804882
Both the system-wide startup file and the user's personal startup file
48814883
can be made <application>psql</application>-version-specific
48824884
by appending a dash and the <productname>PostgreSQL</productname>
4883-
major or minor release number to the file name,
4884-
for example <filename>~/.psqlrc-9.2</filename> or
4885-
<filename>~/.psqlrc-9.2.5</filename>. The most specific
4886-
version-matching file will be read in preference to a
4887-
non-version-specific file.
4885+
major or minor release identifier to the file name,
4886+
for example <filename>~/.psqlrc-&majorversion;</filename> or
4887+
<filename>~/.psqlrc-&version;</filename>.
4888+
The most specific version-matching file will be read in preference
4889+
to a non-version-specific file.
4890+
These version suffixes are added after determining the file path
4891+
as explained above.
48884892
</para>
48894893
</listitem>
48904894
</varlistentry>

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp