xref: /aosp_15_r20/external/flashrom/doc/how_to_add_docs.rst (revision 0d6140be3aa665ecc836e8907834fcd3e3b018fc)
1*0d6140beSAndroid Build Coastguard WorkerHow to add or update docs
2*0d6140beSAndroid Build Coastguard Worker=========================
3*0d6140beSAndroid Build Coastguard Worker
4*0d6140beSAndroid Build Coastguard WorkerDocumentation files live in ``/doc`` directory in the source tree, so
5*0d6140beSAndroid Build Coastguard Workeradding or updating documentation follows the same process as changing
6*0d6140beSAndroid Build Coastguard Workerthe code. If you've never done it before, start by carefully
7*0d6140beSAndroid Build Coastguard Workerreading the :doc:`/dev_guide/development_guide`.
8*0d6140beSAndroid Build Coastguard Worker
9*0d6140beSAndroid Build Coastguard WorkerTo add or update a documentation page, you need to create or modify
10*0d6140beSAndroid Build Coastguard Workeran ``.rst`` file in the ``/doc`` directory and send a patch for
11*0d6140beSAndroid Build Coastguard Workerreview.
12*0d6140beSAndroid Build Coastguard Worker
13*0d6140beSAndroid Build Coastguard WorkerPeople who are registered in MAINTAINERS file for doc/ directory will
14*0d6140beSAndroid Build Coastguard Workerbe automatically added to the patch as reviewers. However, you are
15*0d6140beSAndroid Build Coastguard Workervery welcome to add more reviewers who know the subject. In fact, it
16*0d6140beSAndroid Build Coastguard Workeris always a good idea to add someone who has knowledge of the specific
17*0d6140beSAndroid Build Coastguard Workerarea you are documenting.
18*0d6140beSAndroid Build Coastguard Worker
19*0d6140beSAndroid Build Coastguard WorkerWe are using Sphinx doc engine for documentation (see
20*0d6140beSAndroid Build Coastguard Workerhttps://www.sphinx-doc.org/) and reStructured Text format for content.
21*0d6140beSAndroid Build Coastguard WorkerreStructuredText Primer page has more details
22*0d6140beSAndroid Build Coastguard Workerhttps://www.sphinx-doc.org/en/master/usage/restructuredtext/basics.html#restructuredtext-primer
23*0d6140beSAndroid Build Coastguard Worker
24*0d6140beSAndroid Build Coastguard WorkerBrand new page needs to be added to the appropriate ``index.rst`` file
25*0d6140beSAndroid Build Coastguard Workerunder ``/doc`` directory (that could be a root index file or nested one).
26*0d6140beSAndroid Build Coastguard Worker
27*0d6140beSAndroid Build Coastguard WorkerTo test your changes, build flashrom with documentation and open
28*0d6140beSAndroid Build Coastguard Workergenerated ``.html`` file in the browser. Generated ``.html`` files are
29*0d6140beSAndroid Build Coastguard Workerin meson ``builddir/doc/html`` directory.
30*0d6140beSAndroid Build Coastguard Worker
31*0d6140beSAndroid Build Coastguard WorkerMisc questions
32*0d6140beSAndroid Build Coastguard Worker--------------
33*0d6140beSAndroid Build Coastguard Worker
34*0d6140beSAndroid Build Coastguard Worker* We use CC-BY-4.0 license for documentation.
35*0d6140beSAndroid Build Coastguard Worker* Writing style can be formal or informal, it's mostly up to you, the
36*0d6140beSAndroid Build Coastguard Worker  important thing is to make the text clear, readable and unambiguous. You
37*0d6140beSAndroid Build Coastguard Worker  can insert images if this really helps the readers to understand the
38*0d6140beSAndroid Build Coastguard Worker  instructions.
39*0d6140beSAndroid Build Coastguard Worker* Documentation should be relevant to either flashrom usage or flashrom
40*0d6140beSAndroid Build Coastguard Worker  development
41