mirror-llvm-project/utils/docs
Reid Kleckner 69e2ec6e7c
[docs] Enable colon_fence myst extension, fix admonitions (#208322)
The colon_fence myst extension enables triple-colon fences for
admonitions, as in:

:::{note}
**Regular** _markdown_ text, not code.
:::

Using triple colon fences for admonition blocks helps markdown editors
treat the body as markdown text, rather than fixed-width code with a
syntax highlight.

This change fixes a live doc bug in MyFirstTypoFix.md, which uses this
admonition style:
https://llvm.org/docs/MyFirstTypoFix.html

Currently ":::{note} The code changes presented" leaks through in the
HTML, and this one line change fixes it.
2026-07-08 14:22:31 -07:00
..
llvm_sphinx [docs] Enable colon_fence myst extension, fix admonitions (#208322) 2026-07-08 14:22:31 -07:00
__main__.py
README.md

utils/docs

Common configuration and extensions for all of the sphinx projects in the llvm-project monorepo (e.g. llvm/docs/, clang/docs/, bolt/docs, ...).

This directory is injected into the PYTHONPATH of sphinx-build processes as part of the llvm-project CMake build.

Note: On the command-line, you must manually ensure this directory is part of your PYTHONPATH. For example, to use sphinx-autobuild for projects which support it, you might use:

$ PYTHONPATH=$PWD/utils/docs sphinx-autobuild llvm/docs/ /tmp/sphinx-build

Testing your Environment

To smoke-test your sphinx environment outside of a CMake build, you can use the utils/docs/__main__.py entrypoint (e.g. python3 utils/docs --test).