Re: idea - custom menu

From: Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
To: Nikolay Samokhvalov <samokhvalov(at)gmail(dot)com>
Cc: PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: idea - custom menu
Date: 2018-03-27 04:10:59
Message-ID: CAFj8pRArxfrK5VmFgqMhbLUuY0_Ws3aEwgSUXa55XjS1dzj4aA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

2018-03-27 2:44 GMT+02:00 Nikolay Samokhvalov <samokhvalov(at)gmail(dot)com>:

> On Sat, Mar 3, 2018 at 1:08 PM, Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
> wrote:
>
>> Hi
>>
>
> Hi Pavel, I don't know how I missed this email, but finally I found it :-)
>
>
>> I am looking on project https://github.com/NikolayS/postgres_dba
>>
>> Nice idea, and perfect publicity of typical PostgreSQL maintenance task.
>>
>
> Thank you! It's in very early stage, I'm going to polish existing reports
> and add more soon.
>
>
>>
>> We can allow to call some external applications on some key press (not
>> command) and evaluate their output. mc has F2 for User menu. It can works
>> well with pdmenu or some similar. Some simple menu can be done on we lines
>> with ncurses.
>>
>
>> It can be substitution of some custom commands.
>>
>> Comments, notes?
>>
>
> This is a great idea. Adding more reports means that menu will be very
> long. I considered having two layers of menu, but it will become less
> convenient. First of all because of necessity to press <Enter> after typing
> each command. If user could just press a single button combination, it
> would make working with such thing much more convenient. I would also bind
> some key to allow repeating the last report without going to the main menu
> at all. Had a look at pdmenu – well, if it could be possible to use it
> for postgres_dba, it would be awesome. Does it work with MacOS, by the
> way?
>
> Also (different story), all new Postgres/psql users hate its output for
> wide result sets. Making your pspg more "available" for end users would
> help a lot here – is it possible to ship it with psql itself, at least as
> an optional feature? I don't know anyone who likes default output of wide
> tables in psql. The pspg is very underestimated.
>
> And one more thing (also a different story completely): wouldn't it be
> good to have ability to connect psql to remote Postgres over ssh tunnel
> just with some option in psql? Currently, users need to setup an SSH
> tunnel with "ssh" command first, and only then connect psql, but I see
> that for new users, it's difficult to manage such thing, some of them end
> up opening Postgres to the world (it was mentioned recently in some
> article that at least 700k Postgres instances were found with port 5432
> available for the world, so ssh tunneling option would be great in psql).
>
> And finally: several people asked me to use colors in reports, but it's
> not possible currently in psql – I can use color output for "\echo"
> command now, but I cannot do anything like that for the server's response.
> For instance, it would be nice to make some numbers colored/bold if they
> are above/below some threshold value, for specific column in the server's
> output. It could be \filter command specifying the rules of the output's
> post-processing. Can ncurses be useful for such thing?
>

ncurses can work with color well - what is difficult is parametrization of
psql report builder or some pager, that ca do this work - probably limits
will be different, ...

https://github.com/okbob/pspg

Regards

Pavel

>
> Regards,
> Nikolay
>

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Amit Langote 2018-03-27 04:27:29 Re: ON CONFLICT DO UPDATE for partitioned tables
Previous Message David G. Johnston 2018-03-27 04:03:17 Re: PQHost() undefined behavior if connecting string contains both host and hostaddr types