Patch for psql startup clarity

Поиск
Список
Период
Сортировка
Искать

Patch for psql startup clarity

От:
David Fetter <david@fetter.org>
Дата:
Вложения:
Kind people,

Here's a minor patch for psql and related files that turns instances
of

 \? for help on internal slash commands

into

\? for help on internal slash (i.e. psql) commands

I think this makes it clearer exactly what \? does and how it's
different from \h

Cheers,
D
-- 
David Fetter david@fetter.org http://fetter.org/
phone: +1 510 893 6100    cell: +1 415 235 3778

Re: Patch for psql startup clarity

От:
Markus Bertheau <twanger@bluetwanger.de>
Дата:
В Птн, 30.01.2004, в 23:45, David Fetter пишет:

> \? for help on internal slash (i.e. psql) commands

I think it should be 

\? for help with psql commands

firstly because the adjective "internal" is really subjective and
secondly because the fact that it's internal in whatever way is
completely unimportant and irrelevant to the user.

-- 
Markus Bertheau 

Re: Patch for psql startup clarity

От:
David Fetter <david@fetter.org>
Дата:
On Fri, Jan 30, 2004 at 11:53:19PM +0100, Markus Bertheau wrote:
> В Птн, 30.01.2004, в 23:45, David Fetter пишет:
> 
> > \? for help on internal slash (i.e. psql) commands
> 
> I think it should be 
> 
> \? for help with psql commands

That was my 1st thought, but wanted to make a minimal change.  Yours
is better, tho :)

On a slightly related subject, the patch I made spans 3 of the 17
files that contain that phrase, as I skipped all the .po's and the
stuff in contrib.

I know this is a much longer-term project, but is there some way to
put such things in 1 place?

Cheers,
D
-- 
David Fetter david@fetter.org http://fetter.org/
phone: +1 510 893 6100    cell: +1 415 235 3778

Re: Patch for psql startup clarity

От:
david@fetter.org (David Fetter)
Дата:
In article <20040130230026.GB22997@fetter.org> you wrote:
> On Fri, Jan 30, 2004 at 11:53:19PM +0100, Markus Bertheau wrote:
>> ?? ??????, 30.01.2004, ?? 23:45, David Fetter ??????????:
>> 
>> > \? for help on internal slash (i.e. psql) commands
>> 
>> I think it should be 
>> 
>> \? for help with psql commands
> 
> That was my 1st thought, but wanted to make a minimal change.  Yours
> is better, tho :)
> 
> On a slightly related subject, the patch I made spans 3 of the 17
> files that contain that phrase, as I skipped all the .po's and the
> stuff in contrib.
> 
> I know this is a much longer-term project, but is there some way to
> put such things in 1 place?

Here's the fixed patch :)

Cheers,
D

? psql-help.patch
Index: doc/src/sgml/start.sgml
===================================================================
RCS file: /projects/cvsroot/pgsql-server/doc/src/sgml/start.sgml,v
retrieving revision 1.33
diff -2 -c -r1.33 start.sgml
*** doc/src/sgml/start.sgml	29 Nov 2003 19:51:37 -0000	1.33
--- doc/src/sgml/start.sgml	30 Jan 2004 22:40:44 -0000
***************
*** 322,326 ****
  Type:  \copyright for distribution terms
         \h for help with SQL commands
!        \? for help on internal slash commands
         \g or terminate with semicolon to execute query
         \q to quit
--- 322,326 ----
  Type:  \copyright for distribution terms
         \h for help with SQL commands
!        \? for help on psql commands
         \g or terminate with semicolon to execute query
         \q to quit
Index: doc/src/sgml/ref/psql-ref.sgml
===================================================================
RCS file: /projects/cvsroot/pgsql-server/doc/src/sgml/ref/psql-ref.sgml,v
retrieving revision 1.104
diff -2 -c -r1.104 psql-ref.sgml
*** doc/src/sgml/ref/psql-ref.sgml	20 Jan 2004 23:48:56 -0000	1.104
--- doc/src/sgml/ref/psql-ref.sgml	30 Jan 2004 22:40:46 -0000
***************
*** 525,529 ****
  Type:  \copyright for distribution terms
         \h for help with SQL commands
!        \? for help on internal slash commands
         \g or terminate with semicolon to execute query
         \q to quit
--- 525,529 ----
  Type:  \copyright for distribution terms
         \h for help with SQL commands
!        \? for help on psql commands
         \g or terminate with semicolon to execute query
         \q to quit
Index: src/bin/psql/startup.c
===================================================================
RCS file: /projects/cvsroot/pgsql-server/src/bin/psql/startup.c,v
retrieving revision 1.83
diff -2 -c -r1.83 startup.c
*** src/bin/psql/startup.c	25 Jan 2004 03:07:22 -0000	1.83
--- src/bin/psql/startup.c	30 Jan 2004 22:40:47 -0000
***************
*** 268,272 ****
  						   "Type:  \\copyright for distribution terms\n"
  						   "       \\h for help with SQL commands\n"
! 					   "       \\? for help on internal slash commands\n"
  			  "       \\g or terminate with semicolon to execute query\n"
  						   "       \\q to quit\n\n"),
--- 268,272 ----
  						   "Type:  \\copyright for distribution terms\n"
  						   "       \\h for help with SQL commands\n"
! 					   "       \\? for help on psql commands\n"
  			  "       \\g or terminate with semicolon to execute query\n"
  						   "       \\q to quit\n\n"),
-- 
David Fetter david@fetter.org http://fetter.org/
phone: +1 510 893 6100    cell: +1 415 235 3778

Fascism should more properly be called corporatism, since it is the
merger of state and corporate power.
                                                    Benito Mussolini

Re: Patch for psql startup clarity

От:
Peter Eisentraut <peter_e@gmx.net>
Дата:
Markus Bertheau wrote:
> В Птн, 30.01.2004, в 23:45, David Fetter пишет:
> > \? for help on internal slash (i.e. psql) commands
>
> I think it should be
>
> \? for help with psql commands
>
> firstly because the adjective "internal" is really subjective and
> secondly because the fact that it's internal in whatever way is
> completely unimportant and irrelevant to the user.

Well, it's internal to psql, meaning that it is only available within 
psql.  I think that is a valid and useful point to make, considering 
that people are frequently confused about the nature of psql, the 
frontend.

Re: Patch for psql startup clarity

От:
David Fetter <david@fetter.org>
Дата:
On Sun, Feb 01, 2004 at 08:09:44PM +0100, Peter Eisentraut wrote:
> Markus Bertheau wrote:
> > В Птн, 30.01.2004, в 23:45, David Fetter пишет:
> > > \? for help on internal slash (i.e. psql) commands
> >
> > I think it should be
> >
> > \? for help with psql commands
> >
> > firstly because the adjective "internal" is really subjective and
> > secondly because the fact that it's internal in whatever way is
> > completely unimportant and irrelevant to the user.
> 
> Well, it's internal to psql, meaning that it is only available
> within psql.  I think that is a valid and useful point to make,
> considering that people are frequently confused about the nature of
> psql, the frontend.

Peter,

If you wanted to pick one of the two patches, which one would it be?
If not, what should the patch look like?

Cheers,
D
-- 
David Fetter david@fetter.org http://fetter.org/
phone: +1 510 893 6100    cell: +1 415 235 3778

Re: Patch for psql startup clarity

От:
Markus Bertheau <twanger@bluetwanger.de>
Дата:
On Вск, 2004-02-01 at 20:09 +0100, Peter Eisentraut wrote:
> Markus Bertheau wrote:
> > В Птн, 30.01.2004, в 23:45, David Fetter пишет:
> > > \? for help on internal slash (i.e. psql) commands
> >
> > I think it should be
> >
> > \? for help with psql commands
> >
> > firstly because the adjective "internal" is really subjective and
> > secondly because the fact that it's internal in whatever way is
> > completely unimportant and irrelevant to the user.
> 
> Well, it's internal to psql, meaning that it is only available within 
> psql.

I think "help on psql commands" completely expresses that they are only
available in psql. Do you agree?

-- 
Markus Bertheau 

Re: Patch for psql startup clarity

От:
Tom Lane <tgl@sss.pgh.pa.us>
Дата:
Markus Bertheau  writes:
> On Вск, 2004-02-01 at 20:09 +0100, Peter Eisentraut wrote:
>> Well, it's internal to psql, meaning that it is only available within 
>> psql.

> I think "help on psql commands" completely expresses that they are only
> available in psql. Do you agree?

Just my 2 cents: "help on psql commands" seems fine to me.  "Internal"
doesn't seem very informative here --- it's not clear what "internal"
is in reference to, psql or the total Postgres system.

			regards, tom lane

Re: Patch for psql startup clarity

От:
Peter Eisentraut <peter_e@gmx.net>
Дата:
David Fetter wrote:
> > > \? for help with psql commands

> If you wanted to pick one of the two patches, which one would it be?
> If not, what should the patch look like?

There seems to be a consensus on the form left standing above.  That 
seems OK to me.

Re: Patch for psql startup clarity

От:
David Fetter <david@fetter.org>
Дата:
On Mon, Feb 02, 2004 at 03:12:41PM +0100, Peter Eisentraut wrote:
> David Fetter wrote:
> > > > \? for help with psql commands
> 
> > If you wanted to pick one of the two patches, which one would it
> > be?  If not, what should the patch look like?
> 
> There seems to be a consensus on the form left standing above.  That
> seems OK to me.

Great!

Cheers,
D
-- 
David Fetter david@fetter.org http://fetter.org/
phone: +1 510 893 6100    cell: +1 415 235 3778

Re: Patch for psql startup clarity

От:
Bruce Momjian <pgman@candle.pha.pa.us>
Дата:
Peter Eisentraut wrote:
> David Fetter wrote:
> > > > \? for help with psql commands
> 
> > If you wanted to pick one of the two patches, which one would it be?
> > If not, what should the patch look like?
> 
> There seems to be a consensus on the form left standing above.  That 
> seems OK to me.

Attached patch applied.  Thanks.

---------------------------------------------------------------------------

Welcome to psql 7.5devel, the PostgreSQL interactive terminal.

Type:  \copyright for distribution terms
       \h for help with SQL commands
       \? for help with psql commands
       \g or terminate with semicolon to execute query
       \q to quit

-- 
  Bruce Momjian                        |  http://candle.pha.pa.us
  pgman@candle.pha.pa.us               |  (610) 359-1001
  +  If your life is a hard drive,     |  13 Roberts Road
  +  Christ can be your backup.        |  Newtown Square, Pennsylvania 19073
Index: doc/TODO
===================================================================
RCS file: /cvsroot/pgsql-server/doc/TODO,v
retrieving revision 1.1211
diff -c -c -r1.1211 TODO
*** doc/TODO	12 Feb 2004 18:11:16 -0000	1.1211
--- doc/TODO	12 Feb 2004 19:57:01 -0000
***************
*** 1,6 ****
  TODO list for PostgreSQL
  ========================
! Last updated:		Thu Feb 12 13:11:14 EST 2004
  
  Current maintainer:	Bruce Momjian (pgman@candle.pha.pa.us)
  
--- 1,6 ----
  TODO list for PostgreSQL
  ========================
! Last updated:		Thu Feb 12 13:14:40 EST 2004
  
  Current maintainer:	Bruce Momjian (pgman@candle.pha.pa.us)
  
Index: doc/src/sgml/start.sgml
===================================================================
RCS file: /cvsroot/pgsql-server/doc/src/sgml/start.sgml,v
retrieving revision 1.34
diff -c -c -r1.34 start.sgml
*** doc/src/sgml/start.sgml	12 Feb 2004 16:38:04 -0000	1.34
--- doc/src/sgml/start.sgml	12 Feb 2004 19:57:01 -0000
***************
*** 321,327 ****
   
  Type:  \copyright for distribution terms
         \h for help with SQL commands
!        \? for help on internal slash commands
         \g or terminate with semicolon to execute query
         \q to quit
   
--- 321,327 ----
   
  Type:  \copyright for distribution terms
         \h for help with SQL commands
!        \? for help with psql commands
         \g or terminate with semicolon to execute query
         \q to quit
   
Index: doc/src/sgml/ref/psql-ref.sgml
===================================================================
RCS file: /cvsroot/pgsql-server/doc/src/sgml/ref/psql-ref.sgml,v
retrieving revision 1.104
diff -c -c -r1.104 psql-ref.sgml
*** doc/src/sgml/ref/psql-ref.sgml	20 Jan 2004 23:48:56 -0000	1.104
--- doc/src/sgml/ref/psql-ref.sgml	12 Feb 2004 19:57:05 -0000
***************
*** 524,530 ****
  
  Type:  \copyright for distribution terms
         \h for help with SQL commands
!        \? for help on internal slash commands
         \g or terminate with semicolon to execute query
         \q to quit
  
--- 524,530 ----
  
  Type:  \copyright for distribution terms
         \h for help with SQL commands
!        \? for help with psql commands
         \g or terminate with semicolon to execute query
         \q to quit
  
Index: src/bin/psql/startup.c
===================================================================
RCS file: /cvsroot/pgsql-server/src/bin/psql/startup.c,v
retrieving revision 1.83
diff -c -c -r1.83 startup.c
*** src/bin/psql/startup.c	25 Jan 2004 03:07:22 -0000	1.83
--- src/bin/psql/startup.c	12 Feb 2004 19:57:08 -0000
***************
*** 267,274 ****
  			printf(gettext("Welcome to %s %s, the PostgreSQL interactive terminal.\n\n"
  						   "Type:  \\copyright for distribution terms\n"
  						   "       \\h for help with SQL commands\n"
! 					   "       \\? for help on internal slash commands\n"
! 			  "       \\g or terminate with semicolon to execute query\n"
  						   "       \\q to quit\n\n"),
  				   pset.progname, PG_VERSION);
  #ifdef USE_SSL
--- 267,274 ----
  			printf(gettext("Welcome to %s %s, the PostgreSQL interactive terminal.\n\n"
  						   "Type:  \\copyright for distribution terms\n"
  						   "       \\h for help with SQL commands\n"
! 						   "       \\? for help with psql commands\n"
! 						   "       \\g or terminate with semicolon to execute query\n"
  						   "       \\q to quit\n\n"),
  				   pset.progname, PG_VERSION);
  #ifdef USE_SSL
FAQ