Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Context

ONAP documentation is using reStructuredText (RST) as input format.

...

  • A local one: to verify syntax highlight
  • An advanced one: to check locally the generated HTML files as produced by ONAP

Basic Local Environnement

Many tools are available to write RST files. We propose a solution based on VisualStudioCode that includes a large number of plugins to check that your RST files are correct.

The VisualStudioCode is available here

The useful plugins extension for RST are the following:

As a result, we can see on your environment the RST key words highlighted and some spelling errors as illustrated on the following picture:

Advanced Local Environment

It is possible to preview the HTML produced by ONAP documentation using the Preview button  on the top-right corner.

...

  • to set up the following Python libraries.
  • to configure the RST plugin

Local Python libraries

You must use Python3 version.

...

pip install lfdocs-conf 
pip install rstcheck
pip install doc8
pip install sphinx sphinx-autobuild
pip install sphinxcontrib-blockdiag
pip install sphinxcontrib-needs
pip install sphinxcontrib-plantuml
pip install sphinxcontrib-nwdiag
pip install sphinxcontrib-seqdiag
pip install sphinxcontrib-swaggerdoc
pip install sphinxcontrib-redoc
pip install sphinx_rtd_theme

RST Plugin configuration

In addition, it is important to configure the RST plugin with the following parameter as displayed in the figure

...