diff --git a/src/sophios/cli.py b/src/sophios/cli.py index bca6c548..c892d589 100644 --- a/src/sophios/cli.py +++ b/src/sophios/cli.py @@ -83,6 +83,8 @@ help='Just generates run.sh and exits. Does not actually invoke ./run.sh') group_run.add_argument('--run_local', default=False, action="store_true", help='After generating the cwl file(s), run it on your local machine.') +group_run.add_argument('--generate_cwl_workflow', required=False, default=False, action="store_true", + help='Compile the workflow without pulling the docker image') parser.add_argument('--cwl_inline_subworkflows', default=False, action="store_true", help='Before generating the cwl file, inline all subworkflows.') diff --git a/src/sophios/main.py b/src/sophios/main.py index 3c1d4b08..e7ba57a0 100644 --- a/src/sophios/main.py +++ b/src/sophios/main.py @@ -194,6 +194,9 @@ def main() -> None: print("(This may happen if you installed the graphviz python package") print("but not the graphviz system package.)") + if args.generate_cwl_workflow: + io.write_to_disk(rose_tree, Path('autogenerated/'), True, args.inputs_file) + if args.run_local or args.generate_run_script: # cwl-docker-extract recursively `docker pull`s all images in all subworkflows. # This is important because cwltool only uses `docker run` when executing