From 718bb2cc9c8483bed143d071aa000f9027c74a41 Mon Sep 17 00:00:00 2001 From: Peter Eisentraut Date: Sun, 20 Feb 2000 14:28:28 +0000 Subject: Moved psql \eset and \eshow to \encoding Improved psql's Ctrl-C handling Fixed configure test for sigsetjmp that now even recognizes it if it's a macro --- src/bin/psql/tab-complete.c | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) (limited to 'src/bin/psql/tab-complete.c') diff --git a/src/bin/psql/tab-complete.c b/src/bin/psql/tab-complete.c index f1492e11ed3..9edfc6b6da8 100644 --- a/src/bin/psql/tab-complete.c +++ b/src/bin/psql/tab-complete.c @@ -3,7 +3,7 @@ * * Copyright 2000 by PostgreSQL Global Development Group * - * $Header: /cvsroot/pgsql/src/bin/psql/tab-complete.c,v 1.13 2000/02/20 02:37:40 tgl Exp $ + * $Header: /cvsroot/pgsql/src/bin/psql/tab-complete.c,v 1.14 2000/02/20 14:28:20 petere Exp $ */ /*----------- @@ -198,14 +198,19 @@ char ** psql_completion(char *text, int start, int end) static char * backslash_commands[] = { "\\connect", "\\copy", "\\d", "\\di", "\\di", "\\ds", "\\dS", "\\dv", - "\\da", "\\df", "\\do", "\\dt", "\\e", "\\echo", "\\g", "\\h", "\\i", "\\l", + "\\da", "\\df", "\\do", "\\dt", "\\e", "\\echo", "\\encoding", + "\\g", "\\h", "\\i", "\\l", "\\lo_import", "\\lo_export", "\\lo_list", "\\lo_unlink", - "\\o", "\\p", "\\pset", "\\q", "\\qecho", "\\r", "\\set", "\\t", "\\x", - "\\w", "\\z", "\\!", NULL + "\\o", "\\p", "\\pset", "\\q", "\\qecho", "\\r", "\\set", "\\t", "\\unset", + "\\x", "\\w", "\\z", "\\!", NULL }; (void)end; /* not used */ +#ifdef HAVE_RL_COMPLETION_APPEND_CHARACTER + rl_completion_append_character = ' '; +#endif + /* Clear a few things. */ completion_charp = NULL; completion_charpp = NULL; @@ -547,7 +552,8 @@ char ** psql_completion(char *text, int start, int end) /* If we still don't have anything to match we have to fabricate some sort of default list. If we were to just return NULL, readline automatically attempts filename completion, and that's usually no good. */ - if (matches == NULL) { + if (matches == NULL) + { COMPLETE_WITH_CONST(""); #ifdef HAVE_RL_COMPLETION_APPEND_CHARACTER rl_completion_append_character = '\0'; -- cgit v1.2.3