Skip to content

Commit

Permalink
document API gen & docstring style, update index.md
Browse files Browse the repository at this point in the history
  • Loading branch information
minhnh committed Nov 22, 2024
1 parent 18b2f17 commit 4a2bae4
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 0 deletions.
10 changes: 10 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,16 @@ Checks should use `ruff`'s [default rules](https://docs.astral.sh/ruff/rules/)
except from line length (specified in [`pyproject.toml`](./pyproject.toml)).
A [plugin](https://github.com/astral-sh/ruff-vscode) is also available for VSCode.

## API documentation generation

API documentation is generated with [mkdocstrings](https://mkdocstrings.github.io/).
Following the [recipe for Python](https://mkdocstrings.github.io/recipes/),
the [`gen_api_pages.py` script](./scripts/gen_api_pages.py)
is executed during `mkdocs` execution to generate Markdown pages for all source files.
For the Python docstrings to be handled correctly by `mkdocstrings`, they must
be either in Google, Numpy, or Sphinx style (see [docs](https://mkdocstrings.github.io/python/usage/configuration/docstrings/)).
If not specified, the default style is [Google](https://sphinxcontrib-napoleon.readthedocs.io/en/latest/example_google.html).

## Python version in GitHub action

The package should be built and tested with latest stable Python version,
Expand Down
6 changes: 6 additions & 0 deletions docs/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Template Python package

This is the generated documentation page for the template Python package for the
[SECORO AG](https://www.uni-bremen.de/secoro) at Univerity of Bremen.

Also check out the generated [API documentation](references/).

0 comments on commit 4a2bae4

Please sign in to comment.