Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 19 additions & 4 deletions .github/workflows/sphinx-docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,20 +19,35 @@ jobs:
with:
python-version: '3.10'

- name: Install dependencies
- name: Install dependencies for main docs
working-directory: ./docs
run: |
python -m pip install --upgrade pip
pip install -r docs/requirements.txt
pip install -r requirements.txt

- name: Install dependencies for Python client docs
working-directory: ./client/python/projectairsim/docs
run: |
pip install -r requirements.txt

- name: Build HTML with Sphinx
- name: Build Python client docs
working-directory: ./client/python/projectairsim/docs
run: make html

- name: Build main docs
working-directory: ./docs
run: make html

- name: Copy Python client docs into main docs
run: |
mkdir -p docs/build/html/client_api
cp -r client/python/projectairsim/docs/build/html/* docs/build/html/client_api/

- name: Deploy to gh_page branch
if: github.event_name == 'push'
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./docs/build/html
publish_dir: docs/build/html
publish_branch: gh_page
force_orphan: true
2 changes: 1 addition & 1 deletion client/python/projectairsim/docs/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
SPHINXOPTS ?=
SPHINXBUILD ?= sphinx-build
SOURCEDIR = .
BUILDDIR = _build
BUILDDIR = build

# Put it first so that "make" without argument is like "make help".
help:
Expand Down
6 changes: 4 additions & 2 deletions client/python/projectairsim/docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@
# Add projectairsim src/ folder to the Python path for sphinx to find it
import os
import sys

import sphinx_rtd_theme
sys.path.insert(0, os.path.abspath("../src"))

project = 'Project AirSim'
Expand All @@ -19,5 +21,5 @@
# -- Options for HTML output -------------------------------------------------
# https://www.sphinx-doc.org/en/master/usage/configuration.html#options-for-html-output

html_theme = 'haiku'
html_static_path = ['_static']
html_theme = 'sphinx_rtd_theme'
html_theme_path = [sphinx_rtd_theme.get_html_theme_path()]