Commit ade8e28f authored by Sebastian Heimann's avatar Sebastian Heimann

Merge branch 'master' of gitext:heimann/grond

parents 5ea4529b 37a7de79
......@@ -610,9 +610,9 @@ def command_export(args):
def setup(parser):
parser.add_option(
'--type', dest='type', metavar='TYPE',
choices=('event', 'source', 'vector'),
choices=('event', 'event-yaml', 'source', 'vector'),
help='select type of objects to be exported. Choices: '
'"event" (default), "source", "vector".')
'"event" (default), "event-yaml", "source", "vector".')
parser.add_option(
'--parameters', dest='parameters', metavar='PLIST',
......
......@@ -801,6 +801,10 @@ def export(what, rundirs, type=None, pnames=None, filename=None):
ev = problem.get_source(x).pyrocko_event()
model.dump_events([ev], stream=out)
elif type == 'event-yaml':
ev = problem.get_source(x).pyrocko_event()
guts.dump_all([ev], stream=out)
else:
raise GrondError('invalid argument: type=%s' % repr(type))
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment