Skip to content

rhysfaultless-cpr/documentation-sphinx

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

CPR documentation

Access the site here

This documentation can be build as either webpages or latex/PDF, but is optimized for webpages

Setup

  1. Install Sphinx on your computer.

  2. 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.

  3. Add Live Server as an extension in VS Code.

  4. 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
    
  5. To build the HTML webpages:

    1. Open a new terminal in VS Code

    2. Navigate to the root of the project directory on your computer

    3. Run the command:

      sphinx-build -b html source docs
      
  6. To view the HTML webpages:

    1. In VS Code's file explorer, navigate to cpr-documentation/html/index.html.
    2. 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.
    3. You can stop running the server by clicking the Port: 5500 button in the bottom right of VS Code.
  7. To build PDF files using LaTex:

    1. Open a new teminal

    2. Navigate to the project root directory, and run:

      sphinx-build -b latex doc build-latex
      cd build-latex
      make
      
    3. If you get errors about missing fonts, go to latex/clearpath-latex/fonts and install all the fonts there.