obr.cli

Module that contains the command line app.

Why does this file exist, and why not put this in __main__?

You might be tempted to import things from __main__ later, but that will cause problems: the code will get executed twice:

  • When you run python -mobr python will execute __main__.py as a script. That means there won’t be any obr.__main__ in sys.modules.

  • When you import __main__ it will get executed again (as a module) because there’s no obr.__main__ in sys.modules.

Also see (1) from http://click.pocoo.org/5/setuptools/#setuptools-integration

Module Contents

Functions

common_params(func)

cli(ctx, **kwargs)

submit(ctx, **kwargs)

run(ctx, **kwargs)

Run specified operations

init(ctx, **kwargs)

status(ctx, **kwargs)

query(ctx, **kwargs)

apply(ctx, **kwargs)

reset_workspace(confirmed)

postProcess(ctx, **kwargs)

reset(ctx, **kwargs)

deletes workspace or cases

archive(ctx, **kwargs)

main()

obr.cli.common_params(func)
obr.cli.cli(ctx: click.Context, **kwargs)
obr.cli.submit(ctx: click.Context, **kwargs)
obr.cli.run(ctx: click.Context, **kwargs)

Run specified operations

obr.cli.init(ctx: click.Context, **kwargs)
obr.cli.status(ctx: click.Context, **kwargs)
obr.cli.query(ctx: click.Context, **kwargs)
obr.cli.apply(ctx: click.Context, **kwargs)
obr.cli.reset_workspace(confirmed)
obr.cli.postProcess(ctx: click.Context, **kwargs)
obr.cli.reset(ctx: click.Context, **kwargs)

deletes workspace or cases

obr.cli.archive(ctx: click.Context, **kwargs)
obr.cli.main()