Skip to main content

Build system for LaTeX documents.

Project description

texbuild

texbuild is a build system for LaTeX documents. It provides namespacing for labeled items. Consider a LaTeX document composed of a main file

% main.tex

\documentclass{article}
\begin{document}
This is an equation
\begin{equation}
  f(x) = x \label{equation}
\end{equation}
\input{foo.tex}
Let's refer to Equation~(\ref{equation}).
\end{document}

which includes a subordinate file

% foo.tex

\begin{equation}
  f(x) = x^2 \label{equation}
\end{equation}

In this situation, \ref{equation} is ambiguous because both files use \label{equation} and the namespace for labeled items in LaTeX is global. texbuild fixes this by supporting import semantics:

% main.tex

% -- begin imports --
% import foo as foo
% -- end imports --

\documentclass{article}
\begin{document}
This is an equation
\begin{equation}
  f(x) = x \label{equation} % export
\end{equation}
\input{foo.tex}
We can refer to foo's Equation~(\ref{foo.equation}) or our own Equation~(\ref{equation}).
\end{document}

and

% foo.tex

\begin{equation}
  f(x) = x^2 \label{equation} % export
\end{equation}

Example

To see texbuild in action, install it and use it to build the example LaTeX documemt provided in this repo, by following these steps:

$ pip install texbuild
$ git clone https://github.com/DanielSank/texbuild
$ cd texbuild/example
$ texbuild

This produces `texbuild/example/build/main.pdf`, which illustrates the use of `texbuild`.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

texbuild-0.1.2.tar.gz (5.7 kB view details)

Uploaded Source

Built Distribution

texbuild-0.1.2-py3-none-any.whl (6.7 kB view details)

Uploaded Python 3

File details

Details for the file texbuild-0.1.2.tar.gz.

File metadata

  • Download URL: texbuild-0.1.2.tar.gz
  • Upload date:
  • Size: 5.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.4

File hashes

Hashes for texbuild-0.1.2.tar.gz
Algorithm Hash digest
SHA256 8d8d367aba11bc11e358d401889058c5311de50e2a998ab72eacb5ba010f7b30
MD5 7fcf1ba764e72a8cc1b88da69d2f1be6
BLAKE2b-256 261a53e036a5f7c4e71cef2b9a085647d814647c371c15b8490abba3b7b5e605

See more details on using hashes here.

File details

Details for the file texbuild-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: texbuild-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 6.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.4

File hashes

Hashes for texbuild-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 0164563c70e380c770945585cd32be43743e2d5ae694a22cd4ba9888df6ca441
MD5 3e1f52c86499b4d34629bc854278bdff
BLAKE2b-256 e5f2e32d19dda54c310ad79e9049d3e3a41c61f9000e88983c5847ad7f8a36a8

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page