Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit fb771f9

Browse files
committed
pg_upgrade: trim down --help and doc option descriptions
Previous code had old/new prefixes on option values, e.g. --old-datadir=OLDDATADIR. Remove them, for simplicity; now: --old-datadir=DATADIR. Also update docs to do the same.
1 parent 82233ce commit fb771f9

File tree

2 files changed

+24
-24
lines changed

2 files changed

+24
-24
lines changed

contrib/pg_upgrade/option.c

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -229,17 +229,17 @@ usage(void)
229229
pg_upgrade [OPTION]...\n\
230230
\n\
231231
Options:\n\
232-
-b, --old-bindir=OLDBINDIR old cluster executable directory\n\
233-
-B, --new-bindir=NEWBINDIR new cluster executable directory\n\
232+
-b, --old-bindir=BINDIR old cluster executable directory\n\
233+
-B, --new-bindir=BINDIR new cluster executable directory\n\
234234
-c, --check check clusters only, don't change any data\n\
235-
-d, --old-datadir=OLDDATADIR old cluster data directory\n\
236-
-D, --new-datadir=NEWDATADIR new cluster data directory\n\
235+
-d, --old-datadir=DATADIR old cluster data directory\n\
236+
-D, --new-datadir=DATADIR new cluster data directory\n\
237237
-j, --jobs number of simultaneous processes or threads to use\n\
238238
-k, --link link instead of copying files to new cluster\n\
239239
-o, --old-options=OPTIONS old cluster options to pass to the server\n\
240240
-O, --new-options=OPTIONS new cluster options to pass to the server\n\
241-
-p, --old-port=OLDPORT old cluster port number (default %d)\n\
242-
-P, --new-port=NEWPORT new cluster port number (default %d)\n\
241+
-p, --old-port=PORT old cluster port number (default %d)\n\
242+
-P, --new-port=PORT new cluster port number (default %d)\n\
243243
-r, --retain retain SQL and log files after success\n\
244244
-U, --username=NAME cluster superuser (default \"%s\")\n\
245245
-v, --verbose enable verbose internal logging\n\
@@ -252,10 +252,10 @@ Before running pg_upgrade you must:\n\
252252
shutdown the postmaster servicing the new cluster\n\
253253
\n\
254254
When you run pg_upgrade, you must provide the following information:\n\
255-
the data directory for the old cluster (-d OLDDATADIR)\n\
256-
the data directory for the new cluster (-D NEWDATADIR)\n\
257-
the \"bin\" directory for the old version (-b OLDBINDIR)\n\
258-
the \"bin\" directory for the new version (-B NEWBINDIR)\n\
255+
the data directory for the old cluster (-d DATADIR)\n\
256+
the data directory for the new cluster (-D DATADIR)\n\
257+
the \"bin\" directory for the old version (-b BINDIR)\n\
258+
the \"bin\" directory for the new version (-B BINDIR)\n\
259259
\n\
260260
For example:\n\
261261
pg_upgrade -d oldCluster/data -D newCluster/data -b oldCluster/bin -B newCluster/bin\n\

doc/src/sgml/pgupgrade.sgml

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -79,15 +79,15 @@
7979
<variablelist>
8080

8181
<varlistentry>
82-
<term><option>-b</option> <replaceable>old_bindir</></term>
83-
<term><option>--old-bindir=</option><replaceable>old_bindir</></term>
82+
<term><option>-b</option> <replaceable>bindir</></term>
83+
<term><option>--old-bindir=</option><replaceable>bindir</></term>
8484
<listitem><para>the old cluster executable directory;
8585
environment variable <envar>PGBINOLD</></para></listitem>
8686
</varlistentry>
8787

8888
<varlistentry>
89-
<term><option>-B</option> <replaceable>new_bindir</></term>
90-
<term><option>--new-bindir=</option><replaceable>new_bindir</></term>
89+
<term><option>-B</option> <replaceable>bindir</></term>
90+
<term><option>--new-bindir=</option><replaceable>bindir</></term>
9191
<listitem><para>the new cluster executable directory;
9292
environment variable <envar>PGBINNEW</></para></listitem>
9393
</varlistentry>
@@ -99,15 +99,15 @@
9999
</varlistentry>
100100

101101
<varlistentry>
102-
<term><option>-d</option> <replaceable>old_datadir</></term>
103-
<term><option>--old-datadir=</option><replaceable>old_datadir</></term>
102+
<term><option>-d</option> <replaceable>datadir</></term>
103+
<term><option>--old-datadir=</option><replaceable>datadir</></term>
104104
<listitem><para>the old cluster data directory; environment
105105
variable <envar>PGDATAOLD</></para></listitem>
106106
</varlistentry>
107107

108108
<varlistentry>
109-
<term><option>-D</option> <replaceable>new_datadir</></term>
110-
<term><option>--new-datadir=</option><replaceable>new_datadir</></term>
109+
<term><option>-D</option> <replaceable>datadir</></term>
110+
<term><option>--new-datadir=</option><replaceable>datadir</></term>
111111
<listitem><para>the new cluster data directory; environment
112112
variable <envar>PGDATANEW</></para></listitem>
113113
</varlistentry>
@@ -140,15 +140,15 @@
140140
</varlistentry>
141141

142142
<varlistentry>
143-
<term><option>-p</option> <replaceable>old_port_number</></term>
144-
<term><option>--old-port=</option><replaceable>old_portnum</></term>
143+
<term><option>-p</option> <replaceable>port</></term>
144+
<term><option>--old-port=</option><replaceable>port</></term>
145145
<listitem><para>the old cluster port number; environment
146146
variable <envar>PGPORTOLD</></para></listitem>
147147
</varlistentry>
148148

149149
<varlistentry>
150-
<term><option>-P</option> <replaceable>new_port_number</></term>
151-
<term><option>--new-port=</option><replaceable>new_portnum</></term>
150+
<term><option>-P</option> <replaceable>port</></term>
151+
<term><option>--new-port=</option><replaceable>port</></term>
152152
<listitem><para>the new cluster port number; environment
153153
variable <envar>PGPORTNEW</></para></listitem>
154154
</varlistentry>
@@ -161,8 +161,8 @@
161161
</varlistentry>
162162

163163
<varlistentry>
164-
<term><option>-U</option> <replaceable>user_name</></term>
165-
<term><option>--username=</option><replaceable>user_name</></term>
164+
<term><option>-U</option> <replaceable>username</></term>
165+
<term><option>--username=</option><replaceable>username</></term>
166166
<listitem><para>cluster's super user name; environment
167167
variable <envar>PGUSER</></para></listitem>
168168
</varlistentry>

0 commit comments

Comments
 (0)