parameterize dump images step to work with custom data paths
This commit is contained in:
parent
e424361ed9
commit
07fef7fbab
3 changed files with 19 additions and 9 deletions
|
|
@ -66,9 +66,12 @@ def dump_detail(ctx: click.core.Context):
|
|||
|
||||
|
||||
@cli.command()
|
||||
def dump_images():
|
||||
click.echo('Running dump_images')
|
||||
dump_images_module.dump_images()
|
||||
@click.pass_context
|
||||
def dump_images(ctx: click.core.Context):
|
||||
data_dir = ctx.obj['data_dir']
|
||||
click.echo(f'Running dump_images stored in {data_dir}')
|
||||
listing_paths = sorted(list(pathlib.Path(data_dir).glob("*/listing.json")))
|
||||
dump_images_module.dump_images(listing_paths)
|
||||
|
||||
|
||||
@cli.command()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue