| Safe Haskell | None |
|---|---|
| Language | Haskell2010 |
Text.Pandoc.Filter.Scripting
Synopsis
- runTempPythonScript :: PythonScript -> IO ScriptResult
- addPlotCapture :: FilePath -> PythonScript -> IO PythonScript
- hasBlockingShowCall :: PythonScript -> Bool
- type PythonScript = String
- data ScriptResult
Documentation
Arguments
| :: PythonScript | Content of the script |
| -> IO ScriptResult | Result with exit code. |
Take a python script in string form, write it in a temporary directory, then execute it.
Arguments
| :: FilePath | Path where to save the figure |
| -> PythonScript | Raw code block |
| -> IO PythonScript | Code block with added capture |
Modify a Python plotting script to save the figure to a filename.
hasBlockingShowCall :: PythonScript -> Bool Source #
Detect the presence of a blocking show call, for example "plt.show()"
type PythonScript = String Source #
data ScriptResult Source #
Constructors
| ScriptSuccess | |
| ScriptFailure Int |