rst2xetex(1)

✨ rst2xetex ✨

okay bestie, so this page is the manpage for rst2xetex, and it lives in the text processing section, i.e. section 1. buckle uppp, it's a long one β€” worth it tho πŸ’–


🌸 NAME 🌸

rst2xetex β€” convert reST documents to XeLaTeX πŸ¦‹


πŸŽ€ SYNOPSIS πŸŽ€

rst2xetex [options] [<source> [<destination>]]

πŸ’… DESCRIPTION πŸ’…

So what this does: it generates LaTeX (XeLaTeX/LuaLaTeX) documents from standalone reStructuredText sources. The deets are here in the docs: https://docutils.sourceforge.io/docs/user/latex.html.

It reads from <source> β€” and if you don't hand it a source, it just reads from stdin β€” and it writes to <destination> β€” and if you don't hand it a destination, it writes to stdout.

There's a whole detailed settings reference at https://docutils.sourceforge.io/docs/user/config.html if you wanna go feral with config. 🫢


✨ OPTIONS ✨

General Docutils Options

  • --output-path=<destination>, --output=<destination> β€” the name of the output destination. lowkey this obsoletes the <destination> positional argument. Default: None (stdout). πŸ‘€
  • --title=<title> β€” set the document title as metadata.
  • --generator, -g β€” include a "Generated by Docutils" credit and link. gotta give credit where credit is due πŸ’–
  • --no-generator β€” do NOT include a generator credit.
  • --date, -d β€” include the date at the end of the document (UTC).
  • --time, -t β€” include the time & date (UTC). full timestamp energy ⏰
  • --no-datestamp β€” include no datestamp of any kind. none. zero. nada.
  • --root-prefix=<path> β€” base directory for absolute paths when reading from the local filesystem. Default "".
  • --source-link, -s β€” include a "View document source" link.
  • --source-url=<URL> β€” use <URL> for a source link; this implies --source-link.
  • --no-source-link β€” do NOT include a "View document source" link.
  • --toc-entry-backlinks β€” link from section headers to TOC entries. (default)
  • --toc-top-backlinks β€” link from section headers to the top of the TOC.
  • --no-toc-backlinks β€” disable backlinks to the table of contents.
  • --footnote-backlinks β€” link from footnotes/citations to references. (default)
  • --no-footnote-backlinks β€” disable backlinks from footnotes and citations.
  • --section-numbering β€” enable section numbering by Docutils. (default)
  • --no-section-numbering β€” disable section numbering by Docutils.
  • --strip-comments β€” remove comment elements from the document tree.
  • --leave-comments β€” leave comment elements in the document tree. (default)
  • --strip-elements-with-class=<class> β€” remove all elements with classes="<class>" from the document tree. > ⚠️ Warning: potentially dangerous; use with caution. (Multiple-use option.)
  • --strip-class=<class> β€” remove all classes="<class>" attributes from elements in the document tree. > ⚠️ Warning: potentially dangerous; use with caution. (Multiple-use option.)
  • --report=<level>, -r <level> β€” report system messages at or higher than <level>, where <level> is one of "info" or "1", "warning"/"2" (the default), "error"/"3", "severe"/"4", "none"/"5".
  • --verbose, -v β€” report ALL system messages. (Same as "--report=1".)
  • --quiet, -q β€” report no system messages. (Same as "--report=5".) 🀫
  • --halt=<level> β€” halt execution at system messages at or above <level>. Levels work like in --report. Default: 4 (severe).
  • --strict β€” halt at the slightest problem. Same as "--halt=info". she does not play πŸ’€
  • --exit-status=<level> β€” enable a non-zero exit status for non-halting system messages at or above <level>. Default: 5 (disabled).
  • --debug β€” enable debug-level system messages and diagnostics.
  • --no-debug β€” disable debug output. (default)
  • --warnings=<file> β€” send the output of system messages to <file>.
  • --traceback β€” enable Python tracebacks when Docutils is halted.
  • --no-traceback β€” disable Python tracebacks. (default)
  • --input-encoding=<name[:handler]> β€” specify the encoding, and optionally the error handler, of input text. Default: utf-8.
  • --output-encoding=<name[:handler]> β€” specify the text encoding, and optionally the error handler, for output. Default: utf-8.
  • --error-encoding=<name[:handler]>, -e <name[:handler]> β€” specify text encoding, and optionally the error handler, for error output. Default: system encoding.
  • --language=<tag>, -l <tag> β€” specify the language as a BCP 47 language tag. Default: en.
  • --record-dependencies=<file> β€” write output file dependencies to <file>.
  • --config=<file> β€” read configuration settings from <file>, if it exists.
  • --version, -V β€” show this program's version number and exit.
  • --help, -h β€” show this help message and exit. 🫢

Generic Parser Options

  • --no-file-insertion β€” disable directives that insert the contents of an external file; they get replaced with a "warning" system message instead.
  • --file-insertion-enabled β€” enable directives that insert the contents of an external file. (default)
  • --no-raw β€” disable the "raw" directive; it gets replaced with a "warning" system message.
  • --raw-enabled β€” enable the "raw" directive. (default)
  • --line-length-limit=<length> β€” the maximal number of characters in an input line. Default 10 000.
  • --legacy-ids β€” keep identifiers backwards compatible. Default.
  • --matching-ids β€” explicit targets use identifiers matching the reference name.
  • --validate β€” validate the document tree after parsing.
  • --no-validation β€” do NOT validate the document tree. (default)

reStructuredText Parser Options

  • --pep-references β€” recognize and link to standalone PEP references (like "PEP 258").
  • --pep-base-url=<URL> β€” base URL for PEP references (default "https://peps.python.org/").
  • --pep-file-url-template=<URL> β€” template for the PEP file part of the URL. (default "pep-%04d")
  • --rfc-references β€” recognize and link to standalone RFC references (like "RFC 822").
  • --rfc-base-url=<URL> β€” base URL for RFC references (default "https://tools.ietf.org/html/").
  • --tab-width=<width> β€” set the number of spaces for tab expansion (default 8).
  • --trim-footnote-reference-space β€” remove spaces before footnote references.
  • --leave-footnote-reference-space β€” leave spaces before footnote references.
  • --syntax-highlight=<format> β€” the token name set for parsing code with Pygments, one of "long", "short", or "none" (which means no parsing). Default is "long".
  • --smart-quotes=<yes/no/alt> β€” change straight quotation marks to typographic form, one of "yes", "no", "alt[ernative]" (default "no").
  • --smartquotes-locales=<language:quotes[,language:quotes,...]> β€” the characters to use as "smart quotes" for <language>.
  • --word-level-inline-markup β€” inline markup is recognized at word boundaries only, i.e. adjacent to punctuation or whitespace. Force character-level inline markup recognition with "\" (backslash + space). Default.
  • --character-level-inline-markup β€” inline markup is recognized anywhere, regardless of surrounding characters. Backslash-escapes must be used to avoid unwanted markup recognition. Useful for East Asian languages. Experimental.

Standalone Reader Options

  • --no-doc-title β€” disable the promotion of a lone top-level section title to document title (and the subsequent promotion of a section title to document subtitle; this promotion is enabled by default).
  • --no-doc-info β€” disable the bibliographic field list transform (enabled by default).
  • --section-subtitles β€” activate the promotion of lone subsection titles to section subtitles (disabled by default).
  • --no-section-subtitles β€” deactivate the promotion of lone subsection titles.

LaTeX-Specific Options

  • --documentclass=<documentclass> β€” specify the LaTeX documentclass. Default: "article".
  • --documentoptions=<options> β€” specify document options. Multiple options can be given, separated by commas. Default: "a4paper".
  • --footnote-references=<format> β€” format for footnote references, one of "superscript" or "brackets". Default: "superscript".
  • --use-latex-citations β€” use cite command for citations. (future default)
  • --figure-citations β€” use figure floats for citations (might get mixed with real figures, just so you know). (provisional default)
  • --attribution=<format> β€” format for block quote attributions, one of "dash" (em-dash prefix), "parentheses"/"parens", or "none". Default: "dash".
  • --stylesheet=<file[,file,...]> β€” specify LaTeX packages/stylesheets. A style gets referenced with "usepackage" if the extension is .sty or omitted, and with "input" otherwise. This overrides previous --stylesheet and --stylesheet-path settings.
  • --stylesheet-path=<file[,file,...]> β€” a comma separated list of LaTeX packages/stylesheets. Relative paths are expanded if a matching file is found in the --stylesheet-dirs. With --link-stylesheet, the path is rewritten relative to the output .tex file.
heads up bestie β€” the original page literally has a broken markup artifact right here, it got hiccuped mid-write βœ‹πŸ˜­: System Message: WARNING/2 (debian/tmp/man/rst2xetex.txt:, line 186) Inline emphasis start-string without end-string.
  • --link-stylesheet β€” link to the stylesheet(s) in the output file. (default)
  • --embed-stylesheet β€” embed the stylesheet(s) in the output file. Stylesheets must be accessible during processing.
  • --stylesheet-dirs=<dir[,dir,...]> β€” a comma-separated list of directories where stylesheets are found. Used by --stylesheet-path when expanding relative path arguments. Default: ".".
  • --latex-preamble=<preamble> β€” customization by LaTeX code in the preamble. Default: select "Linux Libertine" fonts.
  • --template=<file> β€” template file. Default: "xelatex.tex".
  • --use-latex-toc β€” table of contents by LaTeX. (default)
  • --use-docutils-toc β€” table of contents by Docutils (without page numbers).
  • --use-part-section β€” add parts on top of the section hierarchy.
  • --use-docutils-docinfo β€” attach author and date to the document info table. (default)
  • --use-latex-docinfo β€” attach author and date to the document title.
  • --topic-abstract β€” typeset abstract as topic. (default)
  • --use-latex-abstract β€” use LaTeX abstract environment for the document's abstract.
  • --hyperlink-color=<color> β€” color of any hyperlinks embedded in text. Default: "blue" (use "false" to disable).
  • --hyperref-options=<options> β€” additional options to the "hyperref" package.
  • --compound-enumerators β€” enable compound enumerators for nested enumerated lists (e.g. "1.2.a.ii").

more coming in part 2, stay tuned bestie πŸ’–

  • --no-compound-enumerators β€” turns OFF compound enumerators for nested enumerated lists. this is the default, bestie, so this is just what you already get. πŸ’…
  • --section-prefix-for-enumerators β€” turns ON section prefixes ("." then subsection and so on) for compound enumerators. so like 2.3.1 energy instead of just vibes. πŸ¦‹ but β€” and this is important β€” it does literally nothing unless you also have --compound-enumerators turned on. no cap. zero effect otherwise. πŸ™ˆ
  • --no-section-prefix-for-enumerators β€” turns OFF those section prefixes for compound enumerators. also the default. we're all just out here defaulting. ✨
  • --section-enumerator-separator=<char> β€” sets the separator that sits between the section number and the enumerator in compound enumerated lists. default: "-". so you get that cute little hyphen moment by default. πŸŽ€
  • --literal-block-env=<environment> β€” when it can, it uses the environment you name for literal-blocks. default: "" β€” which means it falls back to "alltt". she has a backup plan, always. πŸ’œ
  • --table-style=<format> β€” your table aesthetic, pick your fighter: 🌈
    • "standard" β€” horizontal AND vertical lines, the classic
    • "booktabs" β€” LaTeX booktabs style, so only horizontal lines above and below the table, plus one below the header. very clean, very editorial.
    • "borderless" β€” no lines, just vibes
    • default: "standard"
  • --graphicx-option=<option> β€” sets the LaTeX graphicx package option. default: "". that's it, that's the whole thing 🫢
  • --reference-label=<commandname> β€” by default, the latex-writer puts the reference title into hyperreferences. if you want the section number or the page number instead, specify "ref" or "pageref" here. pick your lore. πŸ“–
  • --use-bibtex=<style,bibfile[,bibfile,...]> β€” names the style and the database(s) for bibtex, like "--use-bibtex=unsrt,mydb1,mydb2". ⚠️ Provisional! β€” do not build your whole personality on this one yet, it's still cooking. πŸ’€
  • --legacy-class-functions β€” uses the legacy functions with the class value list for DUtitle and DUadmonition. the old way, the throwback. πŸ™ˆ
  • --new-class-functions β€” uses DUrole and "DUclass" wrappers for class values, and puts admonition content in an environment. this is the default. main character behaviour, genuinely. πŸ‘‘
  • --legacy-column-widths β€” uses the legacy algorithm to figure out table column widths. this is the provisional default right now, so heads up, it's the one you're getting unless you say otherwise. 😭
  • --new-column-widths β€” uses the new algorithm for table column widths. it's marked as the future default, so enjoy it now before it becomes the norm. 🌟
  • --docutils-footnotes β€” footnotes with numbers/symbols courtesy of Docutils. default. πŸ’–
  • --latex-footnotes β€” footnotes with numbers, brought to you by LaTeX. πŸŽ€

and that's the whole page, bestie!! 🫢 you made it all the way to the bottom, which honestly is iconic of you. this was rst2xetex(1) β€” yes, the man page itself is literally named that, she's self-titled, she's the moment. ✨ πŸ’…πŸŒΈ

go forth and xetex responsibly. periodt. πŸ’–

πŸ“¦ where this page comes from