Skip to main content

Cleans up your LaTeX files

Project description


Clean up your LaTeX files.

CircleCI codecov Code style: black PyPi Version GitHub stars PyPi downloads

blacktex is a little tool, helping with the article editing for LaTeX. It removes all comments from a given file and corrects some common anti-patterns. For example, with

blacktex in.tex out.tex

the input file

Because   of $$a+b=c$$ ({\it Pythogoras}),
% @johnny remember to insert name
and $y=2^ng$ with $n=1,...,10$, we have ${\Gamma \over 2}=8.$

is converted to

Because of
a+b = c
and $y = 2^n g$ with $n = 1,\dots,10$, we have $\frac{\Gamma}{2} = 8$.


blacktex is available from the Python Package Index, so with

pip install -U blacktex

you can install/upgrade.


To run the tests, simply check out this repository and run



blacktex is published under the MIT license.

Project details

Download files

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

Files for blacktex, version 0.2.1
Filename, size File type Python version Upload date Hashes
Filename, size blacktex-0.2.1-py3-none-any.whl (7.0 kB) File type Wheel Python version py3 Upload date Hashes View hashes
Filename, size blacktex-0.2.1.tar.gz (7.0 kB) File type Source Python version None Upload date Hashes View hashes

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page