2024-12-26 10:58:37 +01:00
|
|
|
# latexpand
|
|
|
|
|
|
|
|
> Simplify LaTeX source files by removing comments and resolving `\include`s, `\input`s, etc.
|
|
|
|
> More information: <https://www.ctan.org/pkg/latexpand>.
|
|
|
|
|
2025-03-28 05:26:23 +02:00
|
|
|
- Simplify the specified source file and save the result to the specified output file:
|
2024-12-26 10:58:37 +01:00
|
|
|
|
2025-03-28 05:26:23 +02:00
|
|
|
`latexpand {{[-o|--output]}} {{path/to/output.tex}} {{path/to/file.tex}}`
|
2024-12-26 10:58:37 +01:00
|
|
|
|
|
|
|
- Do not remove comments:
|
|
|
|
|
2025-03-28 05:26:23 +02:00
|
|
|
`latexpand --keep-comments {{[-o|--output]}} {{path/to/output.tex}} {{path/to/file.tex}}`
|
2024-12-26 10:58:37 +01:00
|
|
|
|
|
|
|
- Do not expand `\include`s, `\input`s etc.:
|
|
|
|
|
2025-03-28 05:26:23 +02:00
|
|
|
`latexpand --keep-includes {{[-o|--output]}} {{path/to/output.tex}} {{path/to/file.tex}}`
|
2024-12-26 10:58:37 +01:00
|
|
|
|
|
|
|
- Expand `\usepackage`s as far as the corresponding STY files can be found:
|
|
|
|
|
2025-03-28 05:26:23 +02:00
|
|
|
`latexpand --expand-usepackage {{[-o|--output]}} {{path/to/output.tex}} {{path/to/file.tex}}`
|
2024-12-26 10:58:37 +01:00
|
|
|
|
|
|
|
- Inline the specified BBL file:
|
|
|
|
|
2025-03-28 05:26:23 +02:00
|
|
|
`latexpand --expand-bbl {{path/to/bibliography.bbl}} {{[-o|--output]}} {{path/to/output.tex}} {{path/to/file.tex}}`
|