mirror of
https://github.com/postgres/postgres.git
synced 2025-12-12 02:37:31 +03:00
Here is a patch that does just that, while maintaining the
"traditional" behavior, so the change should be transparent. Use the command "\pset pager always" to turn it on. Anything else does the normal toggle between "on" and "off" Greg Sabino Mullane
This commit is contained in:
@@ -3,7 +3,7 @@
|
||||
*
|
||||
* Copyright 2000 by PostgreSQL Global Development Group
|
||||
*
|
||||
* $Header: /cvsroot/pgsql/src/bin/psql/common.c,v 1.51 2002/10/29 19:35:33 momjian Exp $
|
||||
* $Header: /cvsroot/pgsql/src/bin/psql/common.c,v 1.52 2002/11/08 19:12:21 momjian Exp $
|
||||
*/
|
||||
#include "postgres_fe.h"
|
||||
#include "common.h"
|
||||
@@ -548,7 +548,7 @@ PageOutput(int lines, bool pager)
|
||||
struct winsize screen_size;
|
||||
|
||||
result = ioctl(fileno(stdout), TIOCGWINSZ, &screen_size);
|
||||
if (result == -1 || lines > screen_size.ws_row)
|
||||
if (result == -1 || lines > screen_size.ws_row || pager > 1)
|
||||
{
|
||||
#endif
|
||||
pagerprog = getenv("PAGER");
|
||||
|
||||
Reference in New Issue
Block a user