adamspy.aviewpy package

Submodules

adamspy.aviewpy.aviewpy module

adamspy.aviewpy.aviewpy.no_start_scripts(cwd: pathlib.Path, skip: List[str] = None, preserve_log_file=True)[source]

Moves all startup script files NOT named in :arg:skip to a temporary directory on entry. Moves them back on exit.

Parameters:
  • cwd (Path) – Current working directory
  • scripts (str, optional) – Names of scripts to move. Nonexistent files are ignored, by default [‘aviewBS.cmd’, ‘aview.cmd’, ‘aviewAS.cmd’]
adamspy.aviewpy.aviewpy.run_commands(cmds: List[str], cwd: pathlib.Path, delete_log=True, timeout=300, mdi: Union[List[T], str] = None)[source]

Runs the commands in :arg:cmds in an isolated Adams View session. Ignores any startup scripts (i.e. aviewBS.cmd, aview.cmd, aviewAS.cmd) in the working directory.

Parameters:
  • cmds (List[str]) – Commands to run (Adams View Command Language)
  • cwd (Path) – Working directory
adamspy.aviewpy.aviewpy.run_script(script_file: pathlib.Path, cwd: pathlib.Path = None, delete_log=True, timeout=300, mdi: Union[List[T], str] = None)[source]

Runs the commands in :arg:script_file in an isolated Adams View session. Ignores any startup scripts (i.e. aviewBS.cmd, aview.cmd, aviewAS.cmd) in the working directory.

Parameters:
  • cmds (List[str]) – Commands to run (Adams View Command Language)
  • cwd (Path) – Working directory

Module contents