Ask Your Question

Revision history [back]

Code highlighting and execution in sagetex

Is there a version of \begin{sageblock} my multiline code \end{sageblock} that has code highlighting and line numbering like the sagecommandline environment and code execution?

Of course typesetting with lstlistings and execution with sagesilent could be a workaround, but it would seem to require me to have the same code in my document twice. And that I find unacceptable.