1
0
mirror of https://github.com/openSUSE/osc.git synced 2025-08-30 18:04:11 +02:00

make "osc rdiff" run with a pager

We also do this for "osc request show -d" and similar friends.

Also, make run_pager() handle the case where the string is empty,
instead of having to make the caller handle it.
This commit is contained in:
Vincent Untz
2010-09-10 17:28:45 +02:00
committed by Marcus Huewe
parent 8e92cebaf2
commit e78e4f3151
2 changed files with 16 additions and 12 deletions

View File

@@ -3072,6 +3072,9 @@ def get_default_pager():
def run_pager(message):
import tempfile, sys
if not message:
return
if not sys.stdout.isatty():
print message
else: