Versions Compared

Key

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

...

  • sphinxcontrib.blockdiag
  • sphinxcontrib.sphinxcontrib-needs
  • sphinxcontrib.sphinxcontrib-plantuml
  • sphinxcontrib.nwdiag
  • sphinxcontrib.seqdiag
  • sphinxcontrib.swaggerdoc
  • sphinxcontrib.redoc
  • sphinx_rtd_theme

Make sure you are in a Python 3 environment.

...

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

...

Conf Path: ${workspaceFolder}/docs
Docutils Writer: html
Docutils Writer Part: html_body
Linter:  Executable Path: /usr/bin/doc8 or $VIRTUAL_ENV/bin/doc8 if you are in a python 3 virtual env (and launched Visual studio code from it)
Linter: Name: doc8
Sphinx Build Path: /usr/local/bin/sphinx-build or $VIRTUAL_ENV/bin/sphinx-build if you are in a python 3 virtual env (and launched Visual studio code from it)

Note: you an also use the settings.json file under <home>.config/Code/User and add the following properties

{
"restructuredtext.confPath": "${workspaceFolder}/docs",
"restructuredtext.sphinxBuildPath": "/usr/local/bin/sphinx-build",
"restructuredtext.linter.executablePath": "/usr/bin/doc8",
"restructuredtext.linter.name": "doc8"
}

Note: you need to open a Folder associated with the ONAP component