summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/doc
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/doc')
-rw-r--r--Master/texmf-dist/doc/latex/runcode/README2
-rw-r--r--Master/texmf-dist/doc/latex/runcode/runcode.pdfbin245634 -> 247080 bytes
-rw-r--r--Master/texmf-dist/doc/latex/runcode/runcode.tex43
3 files changed, 28 insertions, 17 deletions
diff --git a/Master/texmf-dist/doc/latex/runcode/README b/Master/texmf-dist/doc/latex/runcode/README
index 0aaa36a3040..4b757540427 100644
--- a/Master/texmf-dist/doc/latex/runcode/README
+++ b/Master/texmf-dist/doc/latex/runcode/README
@@ -1,4 +1,4 @@
-LaTeX Package: runcode 2022/08/20 v1.7
+LaTeX Package: runcode 2023/01/18 v1.8
----------------------------------------
The runcode package enables the execution of source code (e.g., R,
Julia, Matlab, shell, Python, etc.) and embed the results in the pdf file
diff --git a/Master/texmf-dist/doc/latex/runcode/runcode.pdf b/Master/texmf-dist/doc/latex/runcode/runcode.pdf
index 2c0f0d4db9c..405f5a26fd3 100644
--- a/Master/texmf-dist/doc/latex/runcode/runcode.pdf
+++ b/Master/texmf-dist/doc/latex/runcode/runcode.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/runcode/runcode.tex b/Master/texmf-dist/doc/latex/runcode/runcode.tex
index 6fbd691ebcf..8751d4234ef 100644
--- a/Master/texmf-dist/doc/latex/runcode/runcode.tex
+++ b/Master/texmf-dist/doc/latex/runcode/runcode.tex
@@ -1,4 +1,4 @@
-% LaTeX Package: runcode 2022/08/20 v1.7
+% LaTeX Package: runcode 2023/01/18 v1.8
%
% Copyright (C) 2020-2022 by Haim Bar and HaiYing Wang
%
@@ -49,7 +49,7 @@ package’s github repository, at \url{https://github.com/Ossifragus/runcode}.
\end{abstract}
\section{Installation}
-\label{sec:org7e4c2ed}
+\label{sec:org1037dff}
You can simply put the runcode.sty file in the \LaTeX{} project folder.
The server mode requires the
@@ -65,9 +65,9 @@ compiling a \LaTeX{} document.
\section{Usage}
-\label{sec:org2d22735}
+\label{sec:org325e4fc}
\subsection{Load the package:}
-\label{sec:orgbfab84d}
+\label{sec:orgbccebff}
\begin{minted}[]{latex}
\usepackage[options]{runcode}
\end{minted}
@@ -77,12 +77,16 @@ Available options are:
\begin{itemize}
\item \texttt{cache}: use cached results.
-\item \texttt{julia}: start server for \href{https://julialang.org/}{Julia} (requires
-\href{https://pypi.org/project/talk2stat/}{talk2stat}).
+\item \texttt{fvextra}: use the \href{https://ctan.org/pkg/fvextra}{fvextra} package to show code.
-\item \texttt{matlab}: start server for
-\href{https://www.mathworks.com/products/matlab.html}{MatLab} (requires
-\href{https://pypi.org/project/talk2stat/}{talk2stat}).
+\item \texttt{julia}: start server for \href{https://julialang.org/}{Julia} (requires \href{https://pypi.org/project/talk2stat/}{talk2stat}).
+
+\item \texttt{listings}: use the \href{https://ctan.org/pkg/listings?lang=en}{listings} package to show code.
+
+\item \texttt{matlab}: start server for \href{https://www.mathworks.com/products/matlab.html}{MatLab} (requires \href{https://pypi.org/project/talk2stat/}{talk2stat}).
+
+\item \texttt{minted}: use the \href{https://ctan.org/pkg/minted}{minted} package to show code (requires the \href{https://pygments.org/}{pygments} package).
+This is the default option.
\item \texttt{nominted}: use the \href{https://ctan.org/pkg/fvextra}{fvextra} package
instead of the \href{https://ctan.org/pkg/minted}{minted} package to show
@@ -117,6 +121,14 @@ the code block is controlled through the minted package,
\setminted[R]{linenos, frame=single, bgcolor=lightgray, breaklines=true}
\end{minted}
+Similarly, \href{https://ctan.org/pkg/fvextra}{fvextra} and \href{https://ctan.org/pkg/listings?lang=en}{listings} packages can be customized through the \texttt{\textbackslash{}lstset}
+and \texttt{\textbackslash{}fvset} commands, respectively, e.g.:
+
+\begin{minted}[]{latex}
+\lstset{basicstyle=\large, frame=single}
+\fvset{fontsize=\small, linenos=true, frame=single}
+\end{minted}
+
The outputs from executing codes are displayed in
\href{https://ctan.org/pkg/tcolorbox?lang=en}{tcolorbox}, so the style can
be customized with \texttt{\textbackslash{}tcbset},
@@ -127,7 +139,7 @@ be customized with \texttt{\textbackslash{}tcbset},
\end{minted}
\subsection{Basic commands:}
-\label{sec:org1b11cd1}
+\label{sec:org88340c8}
\begin{itemize}
\item \texttt{\textbackslash{}runExtCode\{Arg1\}\{Arg2\}\{Arg3\}[Arg4]} runs an external code.
@@ -144,9 +156,7 @@ else), use cached results (see more about the cache below).
\end{itemize}
\item \texttt{\textbackslash{}showCode\{Arg1\}\{Arg2\}[Arg3][Arg4]} shows the source code, using
-\href{https://ctan.org/pkg/minted}{minted} for a pretty layout or
-\href{https://ctan.org/pkg/fvextra}{fvextra} (if
-\href{https://pygments.org/}{pygments} is not installed).
+\href{https://ctan.org/pkg/minted}{minted} (requires \href{https://pygments.org/}{pygments}), \href{https://ctan.org/pkg/fvextra}{fvextra}, or \href{https://ctan.org/pkg/listings?lang=en}{listings}.
\begin{itemize}
\item \texttt{Arg1} is the programming language.
@@ -188,7 +198,7 @@ text.
\end{itemize}
\subsection{Language specific shortcuts:}
-\label{sec:org154f922}
+\label{sec:org591e87e}
\href{https://julialang.org/}{Julia}
\begin{itemize}
@@ -314,8 +324,9 @@ a file on the disk and then be called.
\section{Revisions}
-\label{sec:orgf446497}
+\label{sec:orgf884e2e}
\begin{itemize}
+\item v1.8, January 18, 2023, add support to \href{https://ctan.org/pkg/listings?lang=en}{listings.}
\item v1.7, August 20, 2022: changed the tmp/ folder to generated/ in order to
conform with CTAN suggestions; renamed the troubleshooting file.
\item v1.6, August 10, 2022: stop only configured/running servers; a new
@@ -333,7 +344,7 @@ code files, zero bytes in output files.)
\end{itemize}
\section{Contributing}
-\label{sec:org0730899}
+\label{sec:org0dce33b}
We welcome your contributions to this package by opening issues on
GitHub and/or making a pull request. We also appreciate more example
documents written using \texttt{runcode}.