Consistent request-response separators.

This commit is contained in:
Jakub Roztocil 2012-07-29 06:59:51 +02:00
parent f73bfea6b8
commit edf87c3392
2 changed files with 6 additions and 5 deletions

View File

@ -119,7 +119,12 @@ def get_output(args, env, request, response):
with_body=OUT_RESP_BODY in args.output_options)
)
return b''.join(exchange)
output = b'\n\n\n'.join(exchange)
if env.stdout_isatty:
output += b'\n\n'
return output
def get_exist_status(code, allow_redirects=False):

View File

@ -79,9 +79,6 @@ def format(msg, prettifier=None, with_headers=True, with_body=True,
chunks.append(body)
if env.stdout_isatty:
chunks.append(b'\n\n')
return b''.join(chunks)
@ -211,7 +208,6 @@ class OutputProcessor(object):
]
def __init__(self, env, **kwargs):
self.env = env
processors = [
cls(env, **kwargs)
for cls in self.installed_processors