From 26aebe8a9f10a3f956cf1371a099ce8bddec0272 Mon Sep 17 00:00:00 2001 From: liuzzo Date: Fri, 22 Nov 2024 17:03:39 +0100 Subject: [PATCH] try doc --- .github/workflows/documentation.yml | 6 +++--- docs/source/conf.py | 18 +++++++++++++----- docs/source/index.rst | 2 +- 3 files changed, 17 insertions(+), 9 deletions(-) diff --git a/.github/workflows/documentation.yml b/.github/workflows/documentation.yml index 17f8bea..e0d7bf4 100644 --- a/.github/workflows/documentation.yml +++ b/.github/workflows/documentation.yml @@ -16,12 +16,12 @@ jobs: pip install sphinx sphinx_rtd_theme myst_parser - name: Sphinx build run: | - make.bat html + sphinx-build docs _build - name: Deploy to GitHub Pages uses: peaceiris/actions-gh-pages@v3 if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/main' }} with: - publish_branch: master + publish_branch: gh-pages github_token: ${{ secrets.GITHUB_TOKEN }} - publish_dir: docs/_build/ + publish_dir: _build/ force_orphan: true \ No newline at end of file diff --git a/docs/source/conf.py b/docs/source/conf.py index fd871e4..709d76b 100644 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -14,15 +14,23 @@ # -- General configuration --------------------------------------------------- # https://www.sphinx-doc.org/en/master/usage/configuration.html#general-configuration -extensions = [] +extensions = ['sphinx.ext.autosummary', + 'sphinx.ext.napoleon', + 'sphinx.ext.intersphinx', + 'sphinx.ext.githubpages', + 'sphinx.ext.viewcode', + # 'myst_nb', + 'myst_parser', + 'sphinx_copybutton', + 'sphinx_design', + ] templates_path = ['_templates'] -exclude_patterns = [] - +exclude_patterns = ['_build', 'Thumbs.db', '.DS_Store'] # -- Options for HTML output ------------------------------------------------- # https://www.sphinx-doc.org/en/master/usage/configuration.html#options-for-html-output -html_theme = 'alabaster' -html_static_path = ['_static'] +html_theme = 'sphinx_rtd_theme' +html_static_path = ['_static'] \ No newline at end of file diff --git a/docs/source/index.rst b/docs/source/index.rst index b00317a..a363e14 100644 --- a/docs/source/index.rst +++ b/docs/source/index.rst @@ -22,8 +22,8 @@ With pyAML, it WILL be possible to (the software is at conceptualization stage): - **easy and friendly configuration** - many more features - .. toctree:: :maxdepth: 2 :caption: Contents: + apidocs/index