def cli(container, no_name, pretty, stdin): # TODO: -i, -t, -d as added options that override the inspection if container: ins = Inspector(container, no_name, pretty) ins.inspect() print(ins.format_cli()) elif stdin: ins = Inspector() ins.pretty = pretty raw_json = click.get_text_stream('stdin').read() ins.set_facts(raw_json) print(ins.format_cli()) else: raise click.UsageError("usage error")
def cli(container, no_name, pretty, publish_all, memory_limit): # TODO: -i, -t, -d as added options that override the inspection ins = Inspector(container, no_name, pretty, publish_all, memory_limit) ins.inspect() print(ins.format_cli())
def cli(container, no_name, pretty): # TODO: -i, -t, -d as added options that override the inspection ins = Inspector(container, no_name, pretty) ins.inspect() print(ins.format_cli())