blob: 50506d685746a77e84d3ec86c040b105926f49ff [file] [log] [blame]
Heinrich Schuchardt624faee2023-04-07 11:28:00 +02001.. SPDX-License-Identifier: GPL-2.0+:
2
3Documentation Style
4===================
5
6Documentation is crucial for the U-Boot project. It has to encompass the needs
7of different reader groups from first time users to developers and maintainers.
8This requires different types of documentation like tutorials, how-to-guides,
9explanatory texts, and reference.
10
11We want to be able to generate documentation in different target formats. We
12therefore use `Sphinx <https://www.sphinx-doc.org>`_ for the generation of
13documents from reStructured text.
14
15We apply the following rules:
16
17* Documentation files are located in *doc/* or its sub-directories.
18* Each documentation file is added to an index page to allow navigation
19 to the document.
20* For documentation we use reStructured text conforming to the requirements
21 of `Sphinx <https://www.sphinx-doc.org>`_.
22* For documentation within code we follow the Linux kernel guide
Heinrich Schuchardtfefb7e12023-07-09 04:00:06 +020023 `Writing kernel-doc comments <https://www.kernel.org/doc/html/latest/doc-guide/kernel-doc.html>`_.
Heinrich Schuchardt624faee2023-04-07 11:28:00 +020024* We try to stick to 80 columns per line in documents.
25* For tables we prefer simple tables over grid tables. We avoid list tables
26 as they make the reStructured text documents hard to read.
27* Before submitting documentation patches we build the HTML documentation and
28 fix all warnings. The build process is described in
29 :doc:`/build/documentation`.