In the \? output, align the columns consistently.

This commit is contained in:
Peter Eisentraut 2009-03-25 13:14:17 +00:00
parent 3e90346628
commit 842f4bcfe4

View File

@ -3,7 +3,7 @@
*
* Copyright (c) 2000-2009, PostgreSQL Global Development Group
*
* $PostgreSQL: pgsql/src/bin/psql/help.c,v 1.142 2009/03/24 12:57:31 petere Exp $
* $PostgreSQL: pgsql/src/bin/psql/help.c,v 1.143 2009/03/25 13:14:17 petere Exp $
*/
#include "postgres_fe.h"
@ -85,7 +85,7 @@ usage(void)
printf(_("psql is the PostgreSQL interactive terminal.\n\n"));
printf(_("Usage:\n"));
printf(_(" psql [OPTIONS]... [DBNAME [USERNAME]]\n\n"));
printf(_(" psql [OPTION]... [DBNAME [USERNAME]]\n\n"));
printf(_("General options:\n"));
/* Display default database */
@ -166,10 +166,6 @@ slashUsage(unsigned short int pager)
/* if you add/remove a line here, change the row count above */
/*
* if this " is the start of the string then it ought to end there to fit
* in 80 columns >> "
*/
fprintf(output, _("General\n"));
fprintf(output, _(" \\copyright show PostgreSQL usage and distribution terms\n"));
fprintf(output, _(" \\g [FILE] or ; execute query (and send results to file or |pipe)\n"));
@ -196,8 +192,7 @@ slashUsage(unsigned short int pager)
fprintf(output, "\n");
fprintf(output, _("Informational\n"));
fprintf(output, _(" Modifiers: S = show system objects + = Additional detail\n"));
fprintf(output, _(" \\l[+] list all databases\n"));
fprintf(output, _(" (options: S = show system objects, + = additional detail)\n"));
fprintf(output, _(" \\d[S+] list tables, views, and sequences\n"));
fprintf(output, _(" \\d[S+] NAME describe table, view, sequence, or index\n"));
fprintf(output, _(" \\da[S] [PATTERN] list aggregate functions\n"));
@ -220,12 +215,13 @@ slashUsage(unsigned short int pager)
fprintf(output, _(" \\dn[+] [PATTERN] list schemas\n"));
fprintf(output, _(" \\do[S] [PATTERN] list operators\n"));
fprintf(output, _(" \\dp [PATTERN] list table, view, and sequence access privileges\n"));
fprintf(output, _(" \\z [PATTERN] same as \\dp\n"));
fprintf(output, _(" \\ds[S+] [PATTERN] list sequences\n"));
fprintf(output, _(" \\dt[S+] [PATTERN] list tables\n"));
fprintf(output, _(" \\dT[S+] [PATTERN] list data types\n"));
fprintf(output, _(" \\du [PATTERN] list roles (users)\n"));
fprintf(output, _(" \\dv[S+] [PATTERN] list views\n"));
fprintf(output, _(" \\l[+] list all databases\n"));
fprintf(output, _(" \\z [PATTERN] same as \\dp\n"));
fprintf(output, "\n");
fprintf(output, _("Formatting\n"));
@ -252,20 +248,20 @@ slashUsage(unsigned short int pager)
fprintf(output, _(" \\password [USERNAME] securely change the password for a user\n"));
fprintf(output, "\n");
fprintf(output, _("External\n"));
fprintf(output, _("Operating System\n"));
fprintf(output, _(" \\cd [DIR] change the current working directory\n"));
fprintf(output, _(" \\timing [on|off] toggle timing of commands (currently %s)\n"),
ON(pset.timing));
fprintf(output, _(" \\! [COMMAND] execute command in shell or start interactive shell\n"));
fprintf(output, "\n");
fprintf(output, _("Variable\n"));
fprintf(output, _("Variables\n"));
fprintf(output, _(" \\prompt [TEXT] NAME prompt user to set internal variable\n"));
fprintf(output, _(" \\set [NAME [VALUE]] set internal variable, or list all if no parameters\n"));
fprintf(output, _(" \\unset NAME unset (delete) internal variable\n"));
fprintf(output, "\n");
fprintf(output, _("Large Object\n"));
fprintf(output, _("Large Objects\n"));
fprintf(output, _(" \\lo_export LOBOID FILE\n"
" \\lo_import FILE [COMMENT]\n"
" \\lo_list\n"