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:
committed by
Marcus Huewe
parent
8e92cebaf2
commit
e78e4f3151
@@ -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:
|
||||
|
Reference in New Issue
Block a user