diff --git a/.github/workflows/build_sphinx_doc.yml b/.github/workflows/build_sphinx_doc.yml index e69de29..70e8298 100644 --- a/.github/workflows/build_sphinx_doc.yml +++ b/.github/workflows/build_sphinx_doc.yml @@ -0,0 +1,33 @@ +name: sphinx build doc html + +on: + push: + branches: + - main + +jobs: + build-html: + runs-on: ubuntu-latest + permissions: + contents: write + steps: + - uses: actions/checkout@v3 + - name: Set up Python + uses: actions/setup-python@v3 + with: + python-version: '3.9' + - name: Install dependencies + run: | + python -m pip install --upgrade pip + pip install -r sgio/docs/requirements.txt + - name: Build HTML + run: | + cd sgio/docs + make html + - name: Deploy + uses: peaceiris/actions-gh-pages@v3 + with: + publish_branch: gh-pages + github_token: ${{ secrets.GITHUB_TOKEN }} + publish_dir: docs/_build/html + force_orphan: true diff --git a/docs/requirements.txt b/docs/requirements.txt new file mode 100644 index 0000000..89f9141 --- /dev/null +++ b/docs/requirements.txt @@ -0,0 +1,9 @@ +sphinx +sphinx-comments +sphinx-sitemap +sphinx-design +sphinx-gallery +pydata-sphinx-theme +sphinx-prompt +sphinx-copybutton +myst-parser diff --git a/docs/source/conf.py b/docs/source/conf.py index fb4a1cf..30ed4c3 100644 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -53,7 +53,8 @@ # The theme to use for HTML and HTML Help pages. See the documentation for # a list of builtin themes. # -html_theme = 'sphinx_book_theme' +# html_theme = 'sphinx_book_theme' +html_theme = 'pydata_sphinx_theme' # Add any paths that contain custom static files (such as style sheets) here, # relative to this directory. They are copied after the builtin static files,