Re: \ef should probably append semicolons
От | Joshua Tolley |
---|---|
Тема | Re: \ef should probably append semicolons |
Дата | |
Msg-id | e7e0a2570810102027k478fb8a6uc6eda5951bc623c2@mail.gmail.com обсуждение исходный текст |
Ответ на | Re: \ef should probably append semicolons (Tom Lane <tgl@sss.pgh.pa.us>) |
Ответы |
Re: \ef should probably append semicolons
|
Список | pgsql-hackers |
On Fri, Oct 10, 2008 at 7:10 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote: > "Joshua Tolley" <eggyknap@gmail.com> writes: >> The new \ef psql command creates nicely usable "CREATE OR REPLACE >> FUNCTION ..." text based on the function I tell it to edit, but the >> text it creates *doesn't* include a final semicolon, so when I exit my >> editor-of-choice after messing with my function, it doesn't run the >> code I've given it until I type one of my own. This is annoying. > > This is intentional. > > If the semicolon is there, the command will be squirted to the backend > instantaneously upon your exiting the $EDITOR. The potential bad > consequences of that seem to me to outweigh the annoyance factor of > typing ; and return. Something in the back of my mind told me this might have been on purpose -- despite a number of us around a table at PG West agreeing current behavior was a pain. > Now, if you want to fix psql so that even with a semicolon there it > will redisplay the command buffer and wait for a return, then I'd agree > that that's an improvement. I couldn't figure out how to get readline > to cooperate with that ... but I didn't spend a lot of time looking. Mmm... but that's so much harder than a 2 line patch :) Thanks for commenting. I may consider that in the (admittedly unlikely) event I feel like getting personal with readline. - Josh / eggyknap
В списке pgsql-hackers по дате отправления: