texlive[72821] Master/texmf-dist: minted (11nov24)

commits+karl at tug.org commits+karl at tug.org
Mon Nov 11 22:13:25 CET 2024


Revision: 72821
          https://tug.org/svn/texlive?view=revision&revision=72821
Author:   karl
Date:     2024-11-11 22:13:24 +0100 (Mon, 11 Nov 2024)
Log Message:
-----------
minted (11nov24)

Modified Paths:
--------------
    trunk/Master/texmf-dist/doc/latex/minted/CHANGELOG_MINTED_LATEX_PACKAGE.md
    trunk/Master/texmf-dist/doc/latex/minted/minted.pdf
    trunk/Master/texmf-dist/source/latex/minted/minted.dtx
    trunk/Master/texmf-dist/tex/latex/minted/minted.sty

Modified: trunk/Master/texmf-dist/doc/latex/minted/CHANGELOG_MINTED_LATEX_PACKAGE.md
===================================================================
--- trunk/Master/texmf-dist/doc/latex/minted/CHANGELOG_MINTED_LATEX_PACKAGE.md	2024-11-11 21:13:13 UTC (rev 72820)
+++ trunk/Master/texmf-dist/doc/latex/minted/CHANGELOG_MINTED_LATEX_PACKAGE.md	2024-11-11 21:13:24 UTC (rev 72821)
@@ -1,6 +1,23 @@
 # Changelog — minted LaTeX package
 
 
+## v3.3.0 (2024/11/10)
+
+*  Fixed a bug from v3.2.0 that caused errors with unrestricted shell escape
+   (#420).
+
+*  Improved error messages mention the possibility of MiKTeX being used with
+   `-aux-directory` or `-output-directory` without setting a
+   `TEXMF_OUTPUT_DIRECTORY` environment variable (#419).
+
+*  Updated documentation on shell escape for TeX Live.  The `latexminted`
+   executable has been added to TeX Live's list of trusted executables, so
+   `-shell-escape` is no longer required.
+
+*  Added support for `fancyvrb` options `reflabel` and `vspace` (#421).
+
+
+
 ## v3.2.0 (2024/10/29)
 
 *  Fixed compatibility with `\includeonly` by replacing buffer length counters

Modified: trunk/Master/texmf-dist/doc/latex/minted/minted.pdf
===================================================================
(Binary files differ)

Modified: trunk/Master/texmf-dist/source/latex/minted/minted.dtx
===================================================================
--- trunk/Master/texmf-dist/source/latex/minted/minted.dtx	2024-11-11 21:13:13 UTC (rev 72820)
+++ trunk/Master/texmf-dist/source/latex/minted/minted.dtx	2024-11-11 21:13:24 UTC (rev 72821)
@@ -27,7 +27,7 @@
 %<package>\NeedsTeXFormat{LaTeX2e}
 %<package>\ProvidesPackage{minted}
 %<*package>
-    [2024/10/29 v3.2.0 Yet another Pygments shim for LaTeX]
+    [2024/11/10 v3.3.0 Yet another Pygments shim for LaTeX]
 %</package>
 %<*driver>
 \documentclass{ltxdoc}
@@ -463,9 +463,9 @@
 %
 % The \mintedpkg\ package operates by passing code to the |latexminted| Python executable, which performs syntax highlighting and then returns the highlighted code in \LaTeX\ format.
 %
-% Currently, |latexminted| requires special permission to run.  \LaTeX\ must be called with the |-shell-escape| option (TeX Live) or the |-enable-write18| option (MiKTeX).  Note that using |-shell-escape| or |-enable-write18| allows \LaTeX\ to run potentially arbitrary commands on your system.  These should only be used when necessary, with documents from trusted sources.
+% |latexminted| is designed to be compatible with the security requirements for restricted shell escape.  For up-to-date installations of TeX Live 2024+, the |-shell-escape| option is no longer required.  The |latexminted| Python executable has been added to TeX Live's list of trusted executables.
 %
-% |latexminted| is designed to be compatible with the security requirements for restricted shell escape.  Once |latexminted| finishes the security review for restricted shell escape executables, it will function automatically without |-shell-escape| or |-enable-write18|, so long as the default restricted shell escape has not been disabled.  It is possible to benefit from these enhanced security capabilities immediately and avoid the need for |-shell-escape| or |-enable-write18| by manually designating |latexminted| as a trusted executable.
+% For versions of TeX Live before 2024 and for MiKTeX, |latexminted| requires special permission to run.  This can be accomplished by running \LaTeX\ with the |-shell-escape| option (TeX Live) or the |-enable-write18| option (MiKTeX).  Note that using |-shell-escape| or |-enable-write18| allows \LaTeX\ to run potentially arbitrary commands on your system.  These should only be used when necessary, with documents from trusted sources.  An alternative is to manually designate |latexminted| as a trusted executable.
 % \begin{itemize}
 % \item TeX Live:  Copy the variable |shell_escape_commands| from the distribution |texmf.cnf| (something like |<texlive>/<yr>/texmf-dist/web2c/texmf.cnf|) into the user |texmf.cnf| (something like |<texlive>/<yr>/texmf.cnf|), and then add |latexminted| to the |shell_escape_commands| list.  The location of the |texmf.cnf| files can be determined by running |kpsewhich -all texmf.cnf|.  Note that under Windows, this only works when |latexminted| is installed within a TeX Live installation; it is not compatible with |latexminted| being installed in a Python installation.
 % \item MiKTeX:  Add a line |AllowedShellCommands[] = latexminted| to the existing list of allowed commands in |miktex.ini|.  You may want to modify the user-scoped configuration instead of the system-wide configuration.  See the \href{https://docs.miktex.org/manual/miktex.ini.html}{MiKTeX documentation} for more details, particularly |initexmf --edit-config-file| and |initexmf --set-config-value|.
@@ -1412,6 +1412,10 @@
 % If line numbers are displayed, they are based on the range of code that is selected; code that is discarded in selecting the range is not considered in calculating line numbers.
 %
 %
+% \item[reflabel (string) (\meta{none})]
+% \texpkg{fancyvrb} option for creating a label that can be used with |\pageref|.
+%
+%
 %   \item[resetmargins (boolean) (false)]
 %     Resets the left margin inside other environments.
 %   \item[rulecolor (color command) (black)]
@@ -1475,6 +1479,12 @@
 %   \item[texcl (boolean) (false)]
 %     Enables \LaTeX{} code inside comments.
 %     Usage as in package \texpkg{listings}.  See the note under \texttt{escapeinside} regarding math and ligatures.
+%
+%
+% \item[vspace (dimension) (\string\topsep)]
+% \texpkg{fancyvrb} option for setting the value of the usual vertical list space.
+%
+%
 %   \item[texcomments (boolean) (false)]
 %     Enables \LaTeX{} code inside comments.  The newer name for |texcl|.  See the note under |escapeinside| regarding math and ligatures.
 %
@@ -2569,20 +2579,32 @@
 \def\minted at detectconfig@noexecutableorerrlog{%
   \global\boolfalse{minted at canexec}%
   \ifnum\csname c_sys_shell_escape_int\endcsname=1\relax
-    \expandafter\@firstofttwo
+    \expandafter\@firstoftwo
   \else
     \expandafter\@secondoftwo
   \fi
    {\IfFileExists{\MintedErrlogFilename}%
-     {\minted at error{minted v3+ executable is not installed or is not added to PATH,
+     {\minted at error{minted v3+ executable is not installed or is not added to PATH;
+        or MiKTeX is being used with \detokenize{-aux-directory} or
+        \detokenize{-output-directory} without setting a
+        \detokenize{TEXMF_OUTPUT_DIRECTORY} environment variable;
         or there was an unexpected error (check "\MintedErrlogFilename")}}%
-     {\minted at error{minted v3+ executable is not installed or is not added to PATH}}}%
+     {\minted at error{minted v3+ executable is not installed or is not added to PATH;
+        or MiKTeX is being used with \detokenize{-aux-directory} or
+        \detokenize{-output-directory} without setting a
+        \detokenize{TEXMF_OUTPUT_DIRECTORY} environment variable}}}%
    {\IfFileExists{\MintedErrlogFilename}%
      {\minted at error{minted v3+ executable is not installed, is not added to PATH,
         or is not permitted with restricted shell escape;
+        or MiKTeX is being used with \detokenize{-aux-directory} or
+        \detokenize{-output-directory} without setting a
+        \detokenize{TEXMF_OUTPUT_DIRECTORY} environment variable;
         or there was an unexpected error (check "\MintedErrlogFilename")}}%
      {\minted at error{minted v3+ executable is not installed, is not added to PATH,
-        or is not permitted with restricted shell escape}}}}
+        or is not permitted with restricted shell escape;
+        or MiKTeX is being used with \detokenize{-aux-directory} or
+        \detokenize{-output-directory} without setting a
+        \detokenize{TEXMF_OUTPUT_DIRECTORY} environment variable}}}}
 \def\minted at detectconfig@ii{%
   \ifx\minted at timestamp\minted at config@timestamp
     \expandafter\minted at detectconfig@iii
@@ -3166,6 +3188,7 @@
   numbers,
   numbersep,
   obeytabs,
+  reflabel,
   resetmargins,
   rulecolor,
   samepage,
@@ -3179,6 +3202,7 @@
   tab,
   tabcolor=black,
   tabsize,
+  vspace,
   xleftmargin,
   xrightmargin,
 }

Modified: trunk/Master/texmf-dist/tex/latex/minted/minted.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/minted/minted.sty	2024-11-11 21:13:13 UTC (rev 72820)
+++ trunk/Master/texmf-dist/tex/latex/minted/minted.sty	2024-11-11 21:13:24 UTC (rev 72821)
@@ -26,7 +26,7 @@
 %% 
 \NeedsTeXFormat{LaTeX2e}
 \ProvidesPackage{minted}
-    [2024/10/29 v3.2.0 Yet another Pygments shim for LaTeX]
+    [2024/11/10 v3.3.0 Yet another Pygments shim for LaTeX]
 \RequirePackage{catchfile}
 \RequirePackage{etoolbox}
 \RequirePackage{fvextra}[2024/10/16]
@@ -474,20 +474,32 @@
 \def\minted at detectconfig@noexecutableorerrlog{%
   \global\boolfalse{minted at canexec}%
   \ifnum\csname c_sys_shell_escape_int\endcsname=1\relax
-    \expandafter\@firstofttwo
+    \expandafter\@firstoftwo
   \else
     \expandafter\@secondoftwo
   \fi
    {\IfFileExists{\MintedErrlogFilename}%
-     {\minted at error{minted v3+ executable is not installed or is not added to PATH,
+     {\minted at error{minted v3+ executable is not installed or is not added to PATH;
+        or MiKTeX is being used with \detokenize{-aux-directory} or
+        \detokenize{-output-directory} without setting a
+        \detokenize{TEXMF_OUTPUT_DIRECTORY} environment variable;
         or there was an unexpected error (check "\MintedErrlogFilename")}}%
-     {\minted at error{minted v3+ executable is not installed or is not added to PATH}}}%
+     {\minted at error{minted v3+ executable is not installed or is not added to PATH;
+        or MiKTeX is being used with \detokenize{-aux-directory} or
+        \detokenize{-output-directory} without setting a
+        \detokenize{TEXMF_OUTPUT_DIRECTORY} environment variable}}}%
    {\IfFileExists{\MintedErrlogFilename}%
      {\minted at error{minted v3+ executable is not installed, is not added to PATH,
         or is not permitted with restricted shell escape;
+        or MiKTeX is being used with \detokenize{-aux-directory} or
+        \detokenize{-output-directory} without setting a
+        \detokenize{TEXMF_OUTPUT_DIRECTORY} environment variable;
         or there was an unexpected error (check "\MintedErrlogFilename")}}%
      {\minted at error{minted v3+ executable is not installed, is not added to PATH,
-        or is not permitted with restricted shell escape}}}}
+        or is not permitted with restricted shell escape;
+        or MiKTeX is being used with \detokenize{-aux-directory} or
+        \detokenize{-output-directory} without setting a
+        \detokenize{TEXMF_OUTPUT_DIRECTORY} environment variable}}}}
 \def\minted at detectconfig@ii{%
   \ifx\minted at timestamp\minted at config@timestamp
     \expandafter\minted at detectconfig@iii
@@ -956,6 +968,7 @@
   numbers,
   numbersep,
   obeytabs,
+  reflabel,
   resetmargins,
   rulecolor,
   samepage,
@@ -969,6 +982,7 @@
   tab,
   tabcolor=black,
   tabsize,
+  vspace,
   xleftmargin,
   xrightmargin,
 }



More information about the tex-live-commits mailing list.