texlive[69229] Master/texmf-dist: eolang (28dec23)
commits+karl at tug.org
commits+karl at tug.org
Fri Dec 29 00:03:57 CET 2023
Revision: 69229
https://tug.org/svn/texlive?view=revision&revision=69229
Author: karl
Date: 2023-12-29 00:03:57 +0100 (Fri, 29 Dec 2023)
Log Message:
-----------
eolang (28dec23)
Modified Paths:
--------------
trunk/Master/texmf-dist/doc/latex/eolang/DEPENDS.txt
trunk/Master/texmf-dist/doc/latex/eolang/README.md
trunk/Master/texmf-dist/doc/latex/eolang/eolang.pdf
trunk/Master/texmf-dist/source/latex/eolang/eolang.dtx
trunk/Master/texmf-dist/tex/latex/eolang/eolang.sty
Modified: trunk/Master/texmf-dist/doc/latex/eolang/DEPENDS.txt
===================================================================
--- trunk/Master/texmf-dist/doc/latex/eolang/DEPENDS.txt 2023-12-28 23:03:48 UTC (rev 69228)
+++ trunk/Master/texmf-dist/doc/latex/eolang/DEPENDS.txt 2023-12-28 23:03:57 UTC (rev 69229)
@@ -18,6 +18,7 @@
soft comment
soft docshots
soft environ
+soft float
soft href-ul
soft hypdoc
soft hyperxmp
@@ -25,6 +26,7 @@
soft ifmtarg
soft l3build
soft libertine
+soft microtype
soft ncctools
soft scheme-basic
soft setspace
Modified: trunk/Master/texmf-dist/doc/latex/eolang/README.md
===================================================================
--- trunk/Master/texmf-dist/doc/latex/eolang/README.md 2023-12-28 23:03:48 UTC (rev 69228)
+++ trunk/Master/texmf-dist/doc/latex/eolang/README.md 2023-12-28 23:03:57 UTC (rev 69229)
@@ -22,7 +22,7 @@
\end{document}
```
-Otherwise, you can download [`eolang.sty`](https://raw.githubusercontent.com/objectionary/eolang.sty/gh-pages/eolang/eolang.sty) and add to your project.
+Otherwise, you can download [`eolang.sty`](https://yegor256.github.io/eolang/eolang.sty) and add to your project.
If you want to contribute yourself, make a fork, then create a branch,
then run `l3build ctan` in the root directory.
Modified: trunk/Master/texmf-dist/doc/latex/eolang/eolang.pdf
===================================================================
(Binary files differ)
Modified: trunk/Master/texmf-dist/source/latex/eolang/eolang.dtx
===================================================================
--- trunk/Master/texmf-dist/source/latex/eolang/eolang.dtx 2023-12-28 23:03:48 UTC (rev 69228)
+++ trunk/Master/texmf-dist/source/latex/eolang/eolang.dtx 2023-12-28 23:03:57 UTC (rev 69229)
@@ -50,7 +50,7 @@
%<package>\NeedsTeXFormat{LaTeX2e}
%<package>\ProvidesPackage{eolang}
%<*package>
-[2023-08-10 0.15.0 Formulas and Graphs for EO Programming Language]
+[2023-12-28 0.17.0 Formulas and Graphs for EO Programming Language]
%</package>
%<*driver>
\documentclass{ltxdoc}
@@ -86,7 +86,14 @@
% \textbf{\color{red}NB!}
% You must run \TeX{} processor with |--shell-escape| option
% and you must have \href{https://www.perl.org}{Perl} installed.
-% This package doesn't work on Windows.
+% If you omit the |--shell-escape| option, the package will try
+% to use cached files, if they exist. If they don't, compilation will
+% crash. Thus, when you must prepare your document for a compilation
+% without the |--shell-escape| option, run it locally with the option
+% and then package all files (including the files in the |_eolang| directory)
+% into a single ZIP archive.
+%
+% If |--shell-escape| is set, this package doesn't work on Windows.
% \section{Introduction}
%
@@ -771,7 +778,12 @@
% Then, we make a directory where all temporary files will be kept:
% \begin{macrocode}
-\iexec[null]{mkdir -p "\eolang at tmpdir/\jobname"}%
+\ifnum\ShellEscapeStatus=1%
+ \iexec[null]{mkdir -p "\eolang at tmpdir/\jobname"}%
+\else%
+ \message{eolang: Temporary directory "\eolang at tmpdir/\jobname"
+ is not created, because --shell-escape is not set^^J}%
+\fi%
% \end{macrocode}
% \begin{macro}{\eolang at lineno}
@@ -820,7 +832,7 @@
$macro = $ARGV[0];
open(my $fh, '<', $ARGV[1]);
my $tex; { local $/; $tex = <$fh>; }
-print "% This file is auto-generated by 0.15.0\n";
+print "% This file is auto-generated by 0.17.0\n";
print '% There are ', length($tex),
' chars in the input: ', $ARGV[1], "\n";
print '% ---', "\n";
@@ -1002,22 +1014,51 @@
% \end{macrocode}
% \end{macro}
+% \begin{macro}{\eolang at ifabsent}
+% \changes{0.17.0}{2023/12/28}{A new supplementary \texttt{eolang at ifabsent} command added}
+% Then, we define the |\eolang at ifabsent| command, which if a given file is absent, runs a processing command, otherwise just inputs it:
+% \begin{macrocode}
+\makeatletter
+\newcommand\eolang at ifabsent[2]{%
+ \IfFileExists
+ {#1}
+ {%
+ \message{eolang: File "#1" already exists ^^J}%
+ \input{#1}}
+ {%
+ \ifnum\ShellEscapeStatus=1\else%
+ \message{eolang: The --shell-escape command line
+ option is not provided, most probably compilation
+ will fail now:^^J}%
+ \fi%
+ #2%
+ }%
+}
+\makeatother
+% \end{macrocode}
+% \end{macro}
+
% \begin{macro}{phiquation}
+% \changes{0.16.0}{2023/12/27}{The processing of \texttt{phiquation} data is done only if it's the first time processing, otherwise cache is used, thus making processing faster.}
% Then, we define the |phiquation| and the |phiquation*| environments through a supplementary
% |\eolang at process| command:
% \begin{macrocode}
\makeatletter\newcommand\eolang at process[1]{
\def\hash{\eolang at mdfive
- {\eolang at tmpdir/\jobname/phiquation.tex}}%
- \iexec[null]{cp "\eolang at tmpdir/\jobname/phiquation.tex"
- "\eolang at tmpdir/\jobname/\hash.tex"}%
- \message{Start parsing 'phi' at line no. \the\inputlineno^^J}
- \iexec[trace,stdout=\eolang at tmpdir/\jobname/\hash-post.tex]{
- perl "\eolang at tmpdir/eolang-phi.pl"
- '#1'
- "\eolang at tmpdir/\jobname/\hash.tex"
- \ifdefined\eolang at nocomments | perl -pe 's/\%.*(\\n|$)//g'\fi
- \ifdefined\eolang at phiSaveTo > \eolang at phiSaveTo\fi}%
+ {\eolang at tmpdir/\jobname/phiquation.tex}-\the\inputlineno}%
+ \eolang at ifabsent
+ {\eolang at tmpdir/\jobname/\hash-post.tex}
+ {%
+ \iexec[null]{cp "\eolang at tmpdir/\jobname/phiquation.tex"
+ "\eolang at tmpdir/\jobname/\hash.tex"}%
+ \message{Start parsing 'phi' at line no. \the\inputlineno^^J}
+ \iexec[trace,stdout=\eolang at tmpdir/\jobname/\hash-post.tex]{
+ perl "\eolang at tmpdir/eolang-phi.pl"
+ '#1'
+ "\eolang at tmpdir/\jobname/\hash.tex"
+ \ifdefined\eolang at nocomments | perl -pe 's/\%.*(\\n|$)//g'\fi
+ \ifdefined\eolang at phiSaveTo > \eolang at phiSaveTo\fi}%
+ }%
\setcounter{FancyVerbLine}{\value{eolang at lineno}}%
\def\eolang at phiSaveTo{\relax}%
}
@@ -1046,17 +1087,20 @@
\RequirePackage{xstring}
\makeatletter\newcommand\phiq[1]{%
\StrSubstitute{\detokenize{#1}}{'}{'"'"'}[\clean]%
- \iexec[log,trace,quiet,stdout=\eolang at tmpdir/\jobname/phiq.tex]{
- /bin/echo '\clean'}%
- \def\hash{\eolang at mdfive
- {\eolang at tmpdir/\jobname/phiq.tex}}%
- \iexec[null]{cp "\eolang at tmpdir/\jobname/phiq.tex"
- "\eolang at tmpdir/\jobname/\hash.tex"}%
+ \def\hash{\pdf at mdfivesum{\clean}-\the\inputlineno}%
\ifdefined\eolang at nodollar\else\catcode`\$=3 \fi%
- \iexec[trace,stdout=\eolang at tmpdir/\jobname/\hash-post.tex]{
- perl \eolang at tmpdir/eolang-phi.pl 'phiq'
- "\eolang at tmpdir/\jobname/\hash.tex"
- \ifdefined\eolang at nocomments | perl -pe 's/\%.*(\\n|$)//g'\fi}%
+ \eolang at ifabsent
+ {\eolang at tmpdir/\jobname/\hash-phiq-post.tex}
+ {%
+ \iexec[log,trace,quiet,stdout=\eolang at tmpdir/\jobname/phiq.tex]{
+ /bin/echo '\clean'}%
+ \iexec[quiet,null]{cp "\eolang at tmpdir/\jobname/phiq.tex"
+ "\eolang at tmpdir/\jobname/\hash-phiq.tex"}%
+ \iexec[trace,stdout=\eolang at tmpdir/\jobname/\hash-phiq-post.tex]{
+ perl \eolang at tmpdir/eolang-phi.pl 'phiq'
+ "\eolang at tmpdir/\jobname/\hash-phiq.tex"
+ \ifdefined\eolang at nocomments | perl -pe 's/\%.*(\\n|$)//g' \fi}%
+ }%
\ifdefined\eolang at nodollar\else\catcode`\$\active\fi%
}\makeatother
% \end{macrocode}
@@ -1495,6 +1539,7 @@
% \begin{macro}{sodg}
% \changes{0.0.2}{2022/10/20}{The environment \texttt{phigure} renamed to \texttt{sodg} for the sake of better semantic. The graph in the picture is solely a SODG graph, that's why the name \texttt{sodg} is better.}
+% \changes{0.16.0}{2023/12/27}{The processing of \texttt{sodg} data is done only if it's the first time processing, otherwise cache is used, thus making processing faster.}
% Then, we create a new environment |sodg|, as suggested
% \href{https://tex.stackexchange.com/questions/661056}{here}:
% \begin{macrocode}
@@ -1505,16 +1550,20 @@
{\eolang at tmpdir/\jobname/sodg.tex}}
{\end{VerbatimOut}%
\def\hash{\eolang at mdfive
- {\eolang at tmpdir/\jobname/sodg.tex}}%
- \iexec[null]{cp "\eolang at tmpdir/\jobname/sodg.tex"
- "\eolang at tmpdir/\jobname/\hash.tex"}%
+ {\eolang at tmpdir/\jobname/sodg.tex}-\the\inputlineno}%
\catcode`\$=3 %
- \message{Start parsing `sodg' at line no. \the\inputlineno^^J}
- \iexec[trace,stdout=\eolang at tmpdir/\jobname/\hash-post.tex]{
- perl "\eolang at tmpdir/eolang-sodg.pl"
- "\eolang at tmpdir/\jobname/\hash.tex"
- \ifdefined\eolang at nocomments | perl -pe 's/\%.*(\\n|$)//g'\fi
- \ifdefined\eolang at sodgSaveTo > \eolang at sodgSaveTo\fi}%
+ \eolang at ifabsent
+ {\eolang at tmpdir/\jobname/\hash-sodg-post.tex}
+ {%
+ \iexec[null]{cp "\eolang at tmpdir/\jobname/sodg.tex"
+ "\eolang at tmpdir/\jobname/\hash.tex"}%
+ \message{eolang: Start parsing `sodg' at line no. \the\inputlineno^^J}
+ \iexec[trace,stdout=\eolang at tmpdir/\jobname/\hash-sodg-post.tex]{
+ perl "\eolang at tmpdir/eolang-sodg.pl"
+ "\eolang at tmpdir/\jobname/\hash.tex"
+ \ifdefined\eolang at nocomments | perl -pe 's/\%.*(\\n|$)//g'\fi
+ \ifdefined\eolang at sodgSaveTo > \eolang at sodgSaveTo\fi}%
+ }
\catcode`\$\active%
\setcounter{FancyVerbLine}{\value{eolang at lineno}}%
\def\eolang at sodgSaveTo{\relax}%
Modified: trunk/Master/texmf-dist/tex/latex/eolang/eolang.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/eolang/eolang.sty 2023-12-28 23:03:48 UTC (rev 69228)
+++ trunk/Master/texmf-dist/tex/latex/eolang/eolang.sty 2023-12-28 23:03:57 UTC (rev 69229)
@@ -31,7 +31,7 @@
\NeedsTeXFormat{LaTeX2e}
\ProvidesPackage{eolang}
-[2023-08-10 0.15.0 Formulas and Graphs for EO Programming Language]
+[2023-12-28 0.17.0 Formulas and Graphs for EO Programming Language]
@@ -99,7 +99,12 @@
}
\ProcessPgfPackageOptions{/eolang}
-\iexec[null]{mkdir -p "\eolang at tmpdir/\jobname"}%
+\ifnum\ShellEscapeStatus=1%
+ \iexec[null]{mkdir -p "\eolang at tmpdir/\jobname"}%
+\else%
+ \message{eolang: Temporary directory "\eolang at tmpdir/\jobname"
+ is not created, because --shell-escape is not set^^J}%
+\fi%
\makeatletter\newcounter{eolang at lineno}\makeatother
@@ -113,7 +118,7 @@
$macro = $ARGV[0];
open(my $fh, '<', $ARGV[1]);
my $tex; { local $/; $tex = <$fh>; }
-print "% This file is auto-generated by 0.15.0\n";
+print "% This file is auto-generated by 0.17.0\n";
print '% There are ', length($tex),
' chars in the input: ', $ARGV[1], "\n";
print '% ---', "\n";
@@ -287,18 +292,40 @@
\newcommand\phiSaveTo[1]{\def\eolang at phiSaveTo{#1}}
\makeatother
+\makeatletter
+\newcommand\eolang at ifabsent[2]{%
+ \IfFileExists
+ {#1}
+ {%
+ \message{eolang: File "#1" already exists ^^J}%
+ \input{#1}}
+ {%
+ \ifnum\ShellEscapeStatus=1\else%
+ \message{eolang: The --shell-escape command line
+ option is not provided, most probably compilation
+ will fail now:^^J}%
+ \fi%
+ #2%
+ }%
+}
+\makeatother
+
\makeatletter\newcommand\eolang at process[1]{
\def\hash{\eolang at mdfive
- {\eolang at tmpdir/\jobname/phiquation.tex}}%
- \iexec[null]{cp "\eolang at tmpdir/\jobname/phiquation.tex"
- "\eolang at tmpdir/\jobname/\hash.tex"}%
- \message{Start parsing 'phi' at line no. \the\inputlineno^^J}
- \iexec[trace,stdout=\eolang at tmpdir/\jobname/\hash-post.tex]{
- perl "\eolang at tmpdir/eolang-phi.pl"
- '#1'
- "\eolang at tmpdir/\jobname/\hash.tex"
- \ifdefined\eolang at nocomments | perl -pe 's/\%.*(\\n|$)//g'\fi
- \ifdefined\eolang at phiSaveTo > \eolang at phiSaveTo\fi}%
+ {\eolang at tmpdir/\jobname/phiquation.tex}-\the\inputlineno}%
+ \eolang at ifabsent
+ {\eolang at tmpdir/\jobname/\hash-post.tex}
+ {%
+ \iexec[null]{cp "\eolang at tmpdir/\jobname/phiquation.tex"
+ "\eolang at tmpdir/\jobname/\hash.tex"}%
+ \message{Start parsing 'phi' at line no. \the\inputlineno^^J}
+ \iexec[trace,stdout=\eolang at tmpdir/\jobname/\hash-post.tex]{
+ perl "\eolang at tmpdir/eolang-phi.pl"
+ '#1'
+ "\eolang at tmpdir/\jobname/\hash.tex"
+ \ifdefined\eolang at nocomments | perl -pe 's/\%.*(\\n|$)//g'\fi
+ \ifdefined\eolang at phiSaveTo > \eolang at phiSaveTo\fi}%
+ }%
\setcounter{FancyVerbLine}{\value{eolang at lineno}}%
\def\eolang at phiSaveTo{\relax}%
}
@@ -319,17 +346,20 @@
\RequirePackage{xstring}
\makeatletter\newcommand\phiq[1]{%
\StrSubstitute{\detokenize{#1}}{'}{'"'"'}[\clean]%
- \iexec[log,trace,quiet,stdout=\eolang at tmpdir/\jobname/phiq.tex]{
- /bin/echo '\clean'}%
- \def\hash{\eolang at mdfive
- {\eolang at tmpdir/\jobname/phiq.tex}}%
- \iexec[null]{cp "\eolang at tmpdir/\jobname/phiq.tex"
- "\eolang at tmpdir/\jobname/\hash.tex"}%
+ \def\hash{\pdf at mdfivesum{\clean}-\the\inputlineno}%
\ifdefined\eolang at nodollar\else\catcode`\$=3 \fi%
- \iexec[trace,stdout=\eolang at tmpdir/\jobname/\hash-post.tex]{
- perl \eolang at tmpdir/eolang-phi.pl 'phiq'
- "\eolang at tmpdir/\jobname/\hash.tex"
- \ifdefined\eolang at nocomments | perl -pe 's/\%.*(\\n|$)//g'\fi}%
+ \eolang at ifabsent
+ {\eolang at tmpdir/\jobname/\hash-phiq-post.tex}
+ {%
+ \iexec[log,trace,quiet,stdout=\eolang at tmpdir/\jobname/phiq.tex]{
+ /bin/echo '\clean'}%
+ \iexec[quiet,null]{cp "\eolang at tmpdir/\jobname/phiq.tex"
+ "\eolang at tmpdir/\jobname/\hash-phiq.tex"}%
+ \iexec[trace,stdout=\eolang at tmpdir/\jobname/\hash-phiq-post.tex]{
+ perl \eolang at tmpdir/eolang-phi.pl 'phiq'
+ "\eolang at tmpdir/\jobname/\hash-phiq.tex"
+ \ifdefined\eolang at nocomments | perl -pe 's/\%.*(\\n|$)//g' \fi}%
+ }%
\ifdefined\eolang at nodollar\else\catcode`\$\active\fi%
}\makeatother
@@ -722,16 +752,20 @@
{\eolang at tmpdir/\jobname/sodg.tex}}
{\end{VerbatimOut}%
\def\hash{\eolang at mdfive
- {\eolang at tmpdir/\jobname/sodg.tex}}%
- \iexec[null]{cp "\eolang at tmpdir/\jobname/sodg.tex"
- "\eolang at tmpdir/\jobname/\hash.tex"}%
+ {\eolang at tmpdir/\jobname/sodg.tex}-\the\inputlineno}%
\catcode`\$=3 %
- \message{Start parsing `sodg' at line no. \the\inputlineno^^J}
- \iexec[trace,stdout=\eolang at tmpdir/\jobname/\hash-post.tex]{
- perl "\eolang at tmpdir/eolang-sodg.pl"
- "\eolang at tmpdir/\jobname/\hash.tex"
- \ifdefined\eolang at nocomments | perl -pe 's/\%.*(\\n|$)//g'\fi
- \ifdefined\eolang at sodgSaveTo > \eolang at sodgSaveTo\fi}%
+ \eolang at ifabsent
+ {\eolang at tmpdir/\jobname/\hash-sodg-post.tex}
+ {%
+ \iexec[null]{cp "\eolang at tmpdir/\jobname/sodg.tex"
+ "\eolang at tmpdir/\jobname/\hash.tex"}%
+ \message{eolang: Start parsing `sodg' at line no. \the\inputlineno^^J}
+ \iexec[trace,stdout=\eolang at tmpdir/\jobname/\hash-sodg-post.tex]{
+ perl "\eolang at tmpdir/eolang-sodg.pl"
+ "\eolang at tmpdir/\jobname/\hash.tex"
+ \ifdefined\eolang at nocomments | perl -pe 's/\%.*(\\n|$)//g'\fi
+ \ifdefined\eolang at sodgSaveTo > \eolang at sodgSaveTo\fi}%
+ }
\catcode`\$\active%
\setcounter{FancyVerbLine}{\value{eolang at lineno}}%
\def\eolang at sodgSaveTo{\relax}%
More information about the tex-live-commits
mailing list.