Re: \h tab-completion

From: Peter Eisentraut <peter(dot)eisentraut(at)2ndquadrant(dot)com>
To: Andreas Karlsson <andreas(at)proxel(dot)se>, Michael Paquier <michael(dot)paquier(at)gmail(dot)com>, Beena Emerson <memissemerson(at)gmail(dot)com>
Cc: Stephen Frost <sfrost(at)snowman(dot)net>, "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: \h tab-completion
Date: 2017-03-01 13:47:15
Message-ID: ceaf1188-5d7d-a8e1-19aa-8184b5923072@2ndquadrant.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 2/3/17 07:12, Andreas Karlsson wrote:
> On 01/25/2017 07:13 AM, Michael Paquier wrote:
>> What I think you should do is making the code path of
>> \\h smarter with some exceptions by using TailMatchesCS2() for ALTER.
>> There is as well the case of DROP commands that should be treated by
>> the way.
>
> Yes, I think that is correct approach. I have attached a patch where I
> add completion for \h ALTER and \h DROP.

Instead of creating another copy of list_ALTER, let's use the
words_after_create list and write a version of
create_command_generator/drop_command_generator.

--
Peter Eisentraut http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Peter Eisentraut 2017-03-01 13:54:42 Re: [PATCH] Add tab completion for DEALLOCATE
Previous Message Peter Eisentraut 2017-03-01 13:36:55 Re: Change in "policy" on dump ordering?