mirror of
https://github.com/OPM/ResInsight.git
synced 2026-10-24 22:27:55 -05:00
Replace the rips.taskmaestro_helper introspect subcommand with `python -m taskmaestro workflow describe --json`. RimWorkflowDescribeTools converts the describe output (JSON schemas, depends_on, config_values) into the workflow graph used by the Workflow UI. This also adds support for collect dependencies and maps rips.Reservoir to EclipseCase pickers.
30 lines
588 B
Python
30 lines
588 B
Python
"""Command-line entry point: `python -m rips.taskmaestro_helper <subcommand>`."""
|
|
|
|
from __future__ import annotations
|
|
|
|
import sys
|
|
|
|
|
|
def main() -> int:
|
|
if len(sys.argv) < 2:
|
|
print(
|
|
"usage: python -m rips.taskmaestro_helper run ...",
|
|
file=sys.stderr,
|
|
)
|
|
return 2
|
|
|
|
subcommand = sys.argv[1]
|
|
rest = sys.argv[2:]
|
|
|
|
if subcommand == "run":
|
|
from . import run
|
|
|
|
return run.main(rest)
|
|
|
|
print(f"unknown subcommand: {subcommand}", file=sys.stderr)
|
|
return 2
|
|
|
|
|
|
if __name__ == "__main__":
|
|
raise SystemExit(main())
|