Sphinx reStructuredText Cheatsheet

My small cheatsheet for Sphinx.

Other References

Toctree

.. toctree::
   :hidden:
   :glob:
   :titlesonly:

   dir/index.rst
   *

Inline Markup

*italics* is one asterisk
**bold** is two asterisks
``code`` is in backticks

Headings

Heading 1
=========

Heading 2
---------

Heading 3
~~~~~~~~~

Tables

+---------+-------+
| head    | head  |
+=========+=======+
| row     | row   |
+---------+-------+
|| line1  | row   |
|| line2  | row   |
+---------+-------+

or simple:

========= ====== ====================
PARAMETER TYPE   DESCRIPTION
========= ====== ====================
filename  string Filename for update.
========= ====== ====================

Images

.. image:: monet_wildenstein.png
   :width: 309px
   :align: left
   :height: 208px
   :alt: Monet Wildenstein
:doc:`Docker <010-installation/docker>`
`Scrobble example`_

.. _Scrobble example: https://github.com/jcorporation/mympd-scripts/blob/main/ListenBrainz/ListenBrainz-Scrobbler.lua

or inline

`Commandline-Options <020-configuration/index.rst>`__

Code

.. code:: json

   {"type": "sticker", "sticker": "like", "value": "2", "op": "=", "sort": "", "sortdesc": false, "maxentries": 200}

Admonitions

.. danger:: Do not run myMPD as root.

.. warning:: Do not run myMPD as root.

.. tip:: Do not run myMPD as root.

Notes

[1]_

.. [1]

  Supported image mime types are: image/png, image/jpeg, image/webp,
  image/avif, image/svg+xml