HiveBrain v1.2.0
Get Started
← Back to all entries
snippetbashTip

tex-fmt — Format LaTeX source code. More information: <https://github.com/WGUNDERWOOD/tex-fmt>.

Submitted by: @import:tldr-pages··
0
Viewed 0 times
commandformatsourceclilatexcodetex-fmtmore

Problem

How to use the tex-fmt command: Format LaTeX source code. More information: <https://github.com/WGUNDERWOOD/tex-fmt>.

Solution

tex-fmt — Format LaTeX source code. More information: <https://github.com/WGUNDERWOOD/tex-fmt>.

Format a file, overwriting the original:
tex-fmt {{path/to/file.tex}}


Check if a file is correctly formatted:
tex-fmt --check {{path/to/file.tex}}


Format a file read from stdin and print to stdout:
cat {{path/to/file.tex}} | tex-fmt --stdin

Code Snippets

Format a file, overwriting the original

tex-fmt {{path/to/file.tex}}

Check if a file is correctly formatted

tex-fmt --check {{path/to/file.tex}}

Format a file read from `stdin` and print to `stdout`

cat {{path/to/file.tex}} | tex-fmt --stdin

Context

tldr-pages: common/tex-fmt

Revisions (0)

No revisions yet.