mirror of
https://github.com/openSUSE/osc.git
synced 2024-11-10 14:56:14 +01:00
do_prjresults: support --xml option
"prjresults --xml..." simply prints the raw xml which it receives from the api.
This commit is contained in:
parent
203a4eeab5
commit
afa1911798
@ -4384,6 +4384,8 @@ Please submit there instead, or use --nodevelproject to force direct submission.
|
||||
help='hide the legend')
|
||||
@cmdln.option('-c', '--csv', action='store_true',
|
||||
help='csv output')
|
||||
@cmdln.option('', '--xml', action='store_true', default=False,
|
||||
help='generate output in XML')
|
||||
@cmdln.option('-s', '--status-filter', metavar='STATUS',
|
||||
help='show only packages with buildstatus STATUS (see legend)')
|
||||
@cmdln.option('-n', '--name-filter', metavar='EXPR',
|
||||
@ -4417,6 +4419,10 @@ Please submit there instead, or use --nodevelproject to force direct submission.
|
||||
wd = os.curdir
|
||||
project = store_read_project(wd)
|
||||
|
||||
if opts.xml:
|
||||
print ''.join(show_prj_results_meta(apiurl, project))
|
||||
return
|
||||
|
||||
print '\n'.join(get_prj_results(apiurl, project, hide_legend=opts.hide_legend, csv=opts.csv, status_filter=opts.status_filter, name_filter=opts.name_filter, repo=opts.repo, arch=opts.arch, vertical=opts.vertical, show_excluded=opts.show_excluded))
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user