The next step is to add a directory in the doc project where your
project will be included as a submodule and at least one reference
from the doc project to the documentation index in your repository.
-The following sequence will do this over ssh.
+The following sequence will do this over ssh. Please note that the
+reference to your project in *repolist.rst* should be considered
+temporary and removed when you reference it from more appropriate
+place.
.. caution::
ONAP documentation and it's pretty easy to do with
reStructuredText. This is a quick primer, more information is in the
`Sphinx section on Cross-referencing arbitrary locations
-<http://www.sphinx-doc.org/en/stable/markup/inline.html#ref-role>`_.
+<http://www.sphinx-doc.org/en/stable/markup/inline.html>`_.
Within a single document, you can reference another section simply by::
-----------
To test how the documentation renders in HTML, follow these steps:
-Install virtual environment.
+Install `virtual environment <https://pypi.org/project/virtualenv>`_ & create one.
.. code-block:: bash
sudo pip install virtualenv
+ virtualenv onap_docs
+
+Activate `onap_docs` virtual environment.
+
+.. code-block:: bash
+
+ source onap_docs/bin/activate
+
+.. note:: Virtual environment activation has to be performed before attempting to build documentation.
+ Otherwise, tools necessary for the process might not be available.
Download a project repository.
.. code-block:: bash
- git clone http://gerrit.onap.org/r/<project>
+ git clone http://gerrit.onap.org/r/<project>
Download the doc repository.
.. code-block:: bash
cd doc
- sudo pip install -r etc/requirements.txt
+ pip install -r etc/requirements.txt
Copy the conf.py file to your project folder where RST files have been kept:
You can use your Web Browser to open
and check resulting html pages in the output folder.
-.. note:: Be sure to remove the `conf.py`, the static/ files and the output folder from the `<project>/docs/`.This is for testing only. Only commit the rst files and related content.
+.. note:: Be sure to remove the `conf.py`, the static/ files and the output folder from the `<project>/docs/`. This is for testing only. Only commit the rst files and related content.
.. _building-all-documentation:
-----------------
To build the all documentation under doc/, follow these steps:
-Install virtual environment.
+Install `tox <https://pypi.org/project/tox>`_.
.. code-block:: bash
- sudo pip install virtualenv
- cd /local/repo/path/to/project
+ sudo pip install tox
Download the DOC repository.