This documentation can be build as either webpages or latex/PDF, but is optimized for webpages
-
Install Sphinx on your computer.
-
Check if you have Node.js installed on your computer, by opening a terminal and running:
node -v
Install Node.js if it is not on your computer.
-
Add Live Server as an extension in VS Code.
-
Clone this repository. This repository has two Git Submodules, so the easiest way to grab those files is to clone this using the recursive flag:
git clone --recurse-submodules https://github.com/rhysfaultless-cpr/cpr-documentation.git
Alternatively, you can clone the repository, and then add the Git Submodules:
git clone https://github.com/rhysfaultless-cpr/cpr-documentation.git git submodule init git submodule update
-
To build the HTML webpages:
-
Open a new terminal in VS Code
-
Navigate to the root of the project directory on your computer
-
Run the command:
sphinx-build -b html source docs
-
-
To view the HTML webpages:
- In VS Code's file explorer, navigate to cpr-documentation/html/index.html.
- Right click on index.html and select Open with Live Server. This should open a web browser with the latest files stored on your computer in cpr-documentation/build/html.
- You can stop running the server by clicking the Port: 5500 button in the bottom right of VS Code.
-
To build PDF files using LaTex:
-
Open a new teminal
-
Navigate to the project root directory, and run:
sphinx-build -b latex doc build-latex cd build-latex make
-
If you get errors about missing fonts, go to latex/clearpath-latex/fonts and install all the fonts there.
-