Build Sphinx doc projects locally#
These instructions are for local builds using the default Sphinx templates. If you want to build locally using the Rackspace documentation templates, use the Deconst client.
You might want to build locally to find and fix build errors before committing your updates to the GitHub source repository. You also might want to review format and navigational structure locally before you commit updates.
- Python 2.7 or later
- Mac OSx: Install virtualenv <http://docs.python-guide.org/en/latest/dev/virtualenvs/>`_ or pyenv
- Windows: Install Python, pip, and virtualenv. See How to install Python, pip, and virtualenv with PowerShell.
To set up your build environment:
Run the following commands to Activate your virtual environment:
bin activate env-name
Run the following commands to install Sphinx and other required packages:
pip install -r requirements.txt
To build the documentation, run the following commands:
$ cd api-docs $ make clean singlehtml
To view the HTML build results in the target directory,
run the following command:
$ open _build/html/index.html