Skip to content

Commit

Permalink
generate python docs and include in mdbook as part of deploy-book.yaml
Browse files Browse the repository at this point in the history
TODO: write up instructions for how to reproduce locally -- install pipx then pydoc-markdown then ... see ./github/workflows/deploy-book.yaml
  • Loading branch information
calbaker committed Jan 26, 2024
1 parent 389ab46 commit dff52a7
Show file tree
Hide file tree
Showing 6 changed files with 3,784 additions and 2 deletions.
10 changes: 9 additions & 1 deletion .github/workflows/deploy-book.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,11 +32,19 @@ jobs:
MDBOOK_VERSION: 0.4.21
steps:
- uses: actions/checkout@v3
- name: Install mdBook
- name: Install mdBook and supporting dependencies
run: |
curl --proto '=https' --tlsv1.2 https://sh.rustup.rs -sSf -y | sh
rustup update
cargo install --version ${MDBOOK_VERSION} mdbook
- name: Build python docs
run:
sudo apt update
sudo apt install pipx
pipx ensurepath
pipx install pydoc-markdown
pydoc-markdown -I python/ -p fastsim --render-toc > docs/src/python_docs.md

- name: Setup Pages
id: pages
uses: actions/configure-pages@v3
Expand Down
3 changes: 2 additions & 1 deletion docs/.gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
book/
book/
src/python_docs.md
3 changes: 3 additions & 0 deletions docs/src/SUMMARY.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
# Summary

- [Introduction](./intro.md)
- [Documentation](./fastsim-doc.md)
- [Python](./python-doc.md)
- [Rust](./rust-doc.md)
- [How to Update This Book](./how-to-update.md)
5 changes: 5 additions & 0 deletions docs/src/fastsim-doc.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Documentation

## [Python](./python-doc.md)

## [Rust](./rust-doc.md)
Loading

0 comments on commit dff52a7

Please sign in to comment.