description | A LaTeX reformatter / beautifier |
owner | for_llf@sgilles.net |
last change | Mon, 2 Sep 2024 06:17:12 +0000 (2 02:17 -0400) |
URL | git://repo.or.cz/llf.git |
| https://repo.or.cz/llf.git |
push URL | ssh://repo.or.cz/llf.git |
| https://repo.or.cz/llf.git (learn more) |
bundle info | llf.git downloadable bundles |
content tags
|
|
README
This is LLF, which either stands for Lua LaTeX Formatter or LaTeX-Like
Formatter. I forget which.
To use it, run
lua /path/to/llf.lua < input.tex > output.tex
It should reformat your LaTeX in a way that preserves semantic meaning,
yet has intelligent indentation levels. It might not, since it doesn't
actually parse LaTeX, rather it parses a language which is almost LaTeX,
except for the whole Turing Complete bit.
Features:
- Understands verbatim environments
- Might handle your pseudocode environments right
- Won't mangle your align* or tabular environments
- Will treat everything between ‘%noformat{’ and ‘%}noformat’
as verbatim
- Acts like cat(1) if it can't parse your input
- Configure by copying llfrc.lua to ${XDG_CONFIG_HOME}/llf/llfrc.lua
or ${HOME}/.config/llf/llfrc.lua
Dependencies:
- lpeg http://www.inf.puc-rio.br/~roberto/lpeg/lpeg.html
- wcwidth https://luarocks.org/modules/aperezdc/wcwidth
- utf8 (Should be built-in in >=5.3, not sure about other versions)
Licensed under ISC.
Please report bugs to S. Gilles <for_llf@sgilles.net>. Minimal test
cases are great. Patches are even better.