The SKIRT project
advanced radiative transfer for astrophysics
Functions | Variables
pts.do.prompt Namespace Reference

Access PTS command scripts and functions from the interactive Python prompt. More...

Functions

def do (commandline)
 This function performs a command script as if it were invoked from the command line. More...
 

Variables

 prompt
 

Detailed Description

Access PTS command scripts and functions from the interactive Python prompt.

While being imported, this module configures PTS logging for use from the interactive Python prompt. It also defines a function to perform command scripts from the interactive Python prompt.

Function Documentation

◆ do()

def pts.do.prompt.do (   commandline)

This function performs a command script as if it were invoked from the command line.

The The commandline argument should not include the program part (i.e. "pts"); the first token is the specification of the command script. The commandline argument can be one of the following:

  • A single string providing the complete command; in this case the tokens are extracted by splitting on whitespace so a token cannot include whitespace.
  • An iterable of strings specifying the individual tokens of the command; in this case a token can include whitespace.