From 2c9ae15f53aef57d28091b237c193c653c6e80dd Mon Sep 17 00:00:00 2001 From: "W. Trevor King" Date: Sat, 25 Feb 2012 12:53:17 -0500 Subject: [PATCH] Add `new` to list of commands that should not default to using the pager. If the command is run in the pager, access to stdin is tricky, so I avoid it by default. I'd just missed the fact that `new -` used stdin, which caused https://bugzilla.redhat.com/show_bug.cgi?id=751473 $ be new - Traceback (most recent call last): ... File "/usr/lib/python2.7/site-packages/libbe/command/new.py", line 89, in _run summary = self.stdin.readline() ... File "/usr/lib64/python2.7/codecs.py", line 473, in read newdata = self.stream.read(size) IOError: [Errno 9] Bad file descriptor --- libbe/ui/command_line.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libbe/ui/command_line.py b/libbe/ui/command_line.py index 3a5f5c4..d6e8d67 100644 --- a/libbe/ui/command_line.py +++ b/libbe/ui/command_line.py @@ -355,7 +355,7 @@ def main(): command = Class(ui=ui) ui.setup_command(command) - if command.name in ['comment', 'commit', 'import-xml', 'serve']: + if command.name in ['new', 'comment', 'commit', 'import-xml', 'serve']: paginate = 'never' else: paginate = 'auto' -- 2.26.2