Skip to content

Commit

Permalink
Document changes in build.lua files [ci skip]
Browse files Browse the repository at this point in the history
  • Loading branch information
josephwright committed Mar 10, 2018
1 parent 1f45a3e commit e580a86
Showing 1 changed file with 26 additions and 0 deletions.
26 changes: 26 additions & 0 deletions l3build.dtx
Expand Up @@ -547,7 +547,33 @@
% By default this process allows files to be accessed in all standard |texmf| trees; this can be disabled by setting \var{unpacksearch} to |false|.
% \end{buildcmd}
%
% \subsection{The \texttt{build.lua} file}
%
% The \texttt{build.lua} file used to control \pkg{l3build} is a simple Lua file
% which is read during execution. In the current release of \pkg{l3build},
% \texttt{build.lua} is read automatically and can access all of the global
% functions provided by the script. Thus it may contain a simple list of
% variable settings \emph{or} additionally custom code to change the build
% process. A number of example scripts are given in Section~\ref{sec:examples}.
%
% Earlier releases of \pkg{l3build} required that the last line of
% \texttt{build.lua} ran the main script, \emph{i.e.}~ that \texttt{build.lua}
% was what the user called rather than \texttt{l3build.lua}. To allow scripts
% to support both forms \emph{for the transition}, a simple test may be
% included as showing in Figure~\ref{fig:build-compat}.
% \begin{figure}
% \begin{lstlisting}[frame=single,language={[5.2]Lua},gobble = 6]
% if not release_date then
% dofile(kpse.lookup("l3build.lua"))
% end
% \end{lstlisting}
% \caption{Final lines for a \texttt{build.lua} script usable with both older
% and newer releases of \pkg{l3build}.}
% \label{fig:build-compat}
% \end{figure}
%
% \subsection{Example build scripts}
% \label{sec:examples}
%
% An example of a standalone build script for a package that uses self-contained |.dtx| files is shown in Figure~\ref{fig:breqn}.
% Here, the |module| only is defined, and since it doesn't use |.ins| files so the variable \var{unpackfiles} is redefined to run |tex| on the |.dtx| files instead to generate the necessary |.sty| files.
Expand Down

0 comments on commit e580a86

Please sign in to comment.