Hi, I'd like to set a function key in PostgreSQL's psql bindings to execute a predefined query. At the moment, I have tried:
| $include /etc/inputrc | | $if psql | "\e[24~": "\C-a\C-k\\r\n\fSELECT * FROM DashboardQuery;\n" | $endif (The "\\r\n" tells psql to clear its query buffer.) Unfortu- nately, this doesn't work if readline is in "quote mode", e. g. the preceding line contains an opening "'" or '"'. I noticed though that pressing C-c does what I want: It can- cels all active thingies and gives me a clean prompt. Unfortunately, I can't use "\C-c" to invoke it as the key probably gets passed as SIGINT to readline. Is there another way to "call" rl_free_line_state () from a binding defini- tion? TIA, Tim _______________________________________________ Bug-readline mailing list [email protected] http://lists.gnu.org/mailman/listinfo/bug-readline
