1
0
mirror of https://github.com/openSUSE/osc.git synced 2024-12-26 18:06:13 +01:00

Merge branch 'enhance_build_result_watch_output' of https://github.com/lethliel/osc

This commit is contained in:
Marcus Huewe 2016-10-07 10:15:53 +02:00
commit 4e8f06d3b9

View File

@ -5486,6 +5486,7 @@ def get_results(apiurl, project, package, verbose=False, printJoin='', *args, **
# api (unless we keep get_results around as well)... # api (unless we keep get_results around as well)...
result_line_templ = '%(rep)-20s %(arch)-10s %(status)s' result_line_templ = '%(rep)-20s %(arch)-10s %(status)s'
r = [] r = []
printed = False
for results in get_package_results(apiurl, project, package, **kwargs): for results in get_package_results(apiurl, project, package, **kwargs):
r = [] r = []
for res in result_xml_to_dicts(results): for res in result_xml_to_dicts(results):
@ -5513,7 +5514,11 @@ def get_results(apiurl, project, package, verbose=False, printJoin='', *args, **
r.append(result_line_templ % res) r.append(result_line_templ % res)
if printJoin: if printJoin:
if printed:
# will print a newline if already a result was printed (improves readability)
print()
print(printJoin.join(r)) print(printJoin.join(r))
printed = True
return r return r