Re: mprove tab completion for ALTER EXTENSION ADD/DROP

From: vignesh C <vignesh21(at)gmail(dot)com>
To: Michael Paquier <michael(at)paquier(dot)xyz>
Cc: Matheus Alcantara <mths(dot)dev(at)pm(dot)me>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: mprove tab completion for ALTER EXTENSION ADD/DROP
Date: 2023-01-02 07:49:50
Message-ID: CALDaNm3s0MHr1iw716JsacmA4yyCFn4tCw1=3c6Sm2xjvBVYDA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Mon, 5 Dec 2022 at 06:53, Michael Paquier <michael(at)paquier(dot)xyz> wrote:
>
> On Sat, Dec 03, 2022 at 05:34:57PM +0000, Matheus Alcantara wrote:
> > I've tested your patched on current master and seems to be working properly.
> >
> > I'm starting reviewing some patches here, let's see what more experience hackers
> > has to say about this, but as far I can tell is that is working as expected.
>
> + /* ALTER EXTENSION <name> ADD|DROP */
> + else if (Matches("ALTER", "EXTENSION", MatchAny, "ADD|DROP"))
> + COMPLETE_WITH("ACCESS METHOD", "AGGREGATE", "CAST", "COLLATION",
> + "CONVERSION", "DOMAIN", "EVENT TRIGGER", "FOREIGN",
> + "FUNCTION", "MATERIALIZED VIEW", "OPERATOR",
> + "PROCEDURAL LANGUAGE", "PROCEDURE", "LANGUAGE",
> + "ROUTINE", "SCHEMA", "SEQUENCE", "SERVER", "TABLE",
> + "TEXT SEARCH", "TRANSFORM FOR", "TYPE", "VIEW");
> +
> + /* ALTER EXTENSION <name> ADD|DROP FOREIGN*/
> + else if (Matches("ALTER", "EXTENSION", MatchAny, "ADD|DROP", "FOREIGN"))
> + COMPLETE_WITH("DATA WRAPPER", "TABLE");
>
> The DROP could be matched with the objects that are actually part of
> the so-said extension?

The modified v2 version has the changes to handle the same. Sorry for
the delay as I was working on another project.

Regards,
Vignesh

Attachment Content-Type Size
v2-0002-Missing-tab-completion-for-ALTER-EXTENSION-DROP.patch text/x-patch 3.3 KB
v2-0001-Missing-tab-completion-for-ALTER-EXTENSION-ADD.patch text/x-patch 1.8 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message vignesh C 2023-01-02 08:06:00 Re: Support logical replication of DDLs
Previous Message Imseih (AWS), Sami 2023-01-02 04:34:26 Re: Add index scan progress to pg_stat_progress_vacuum