Skip to content

Commit

Permalink
Merge pull request #13 from ali-ramadhan/ali/docs
Browse files Browse the repository at this point in the history
  • Loading branch information
ali-ramadhan authored Jun 30, 2024
2 parents f248341 + a3d678d commit e1fd555
Show file tree
Hide file tree
Showing 10 changed files with 1,074 additions and 37 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ on:

jobs:
pypi_release:
name: Tag release and publishe to PyPI
name: Tag release and publish to PyPI
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
Expand Down
29 changes: 29 additions & 0 deletions .github/workflows/sphinx.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: Deploy docs

on: push

jobs:
docs:
name: Build and deploy Sphinx docs
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: 3.11
- uses: snok/[email protected]
- name: Install dependencies
run: poetry install
- name: Build docs
run: poetry run sphinx-build -M html docs/ docs/build/
- name: Upload artifacts
uses: actions/upload-artifact@v4
with:
name: html-docs
path: docs/build/html/
- name: Deploy
uses: peaceiris/actions-gh-pages@v3
if: github.ref == 'refs/heads/main'
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: docs/build/html/
25 changes: 22 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,25 @@
# matplotloom

Weave your frames into matplotlib animations!
<h1 align="center">
matplotloom
</h1>

<p align="center">
<strong>🧵🧶🪡Weave your frames into matplotlib animations!</strong>
</p>

<p align="center">
<a href="https://www.repostatus.org/#active">
<img alt="Repo status" src="https://www.repostatus.org/badges/latest/active.svg?style=flat-square" />
</a>
<a href="https://mit-license.org">
<img alt="MIT license" src="https://img.shields.io/badge/License-MIT-blue.svg?style=flat-square">
</a>
<a href="https://badge.fury.io/py/matplotloom">
<img alt="PyPI version" src="https://badge.fury.io/py/matplotloom.svg">
</a>
<a href="https://github.com/ali-ramadhan/matplotloom/actions/workflows/testing.yml">
<img alt="Testing" src="https://github.com/ali-ramadhan/matplotloom/actions/workflows/testing.yml/badge.svg">
</a>
</p>

## Why use matplotloom?

Expand Down
2 changes: 0 additions & 2 deletions TODO.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,8 @@
## Documentation

* Add some badges to the README.
* Write some documentation and add some docstrings.
* Add documentation GitHub Action.

## Examples

* Cartopy: https://scitools.org.uk/cartopy/docs/latest/gallery/lines_and_polygons/nightshade.html#sphx-glr-gallery-lines-and-polygons-nightshade-py
* Lorenz63: https://docs.makie.org/stable/
47 changes: 47 additions & 0 deletions docs/conf.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
import os
import sys

# Add loom.py to path.
sys.path.insert(0, os.path.abspath("../.."))

import matplotloom

# Configuration file for the Sphinx documentation builder.
#
# For the full list of built-in configuration values, see the documentation:
# https://www.sphinx-doc.org/en/master/usage/configuration.html

# -- Project information -----------------------------------------------------
# https://www.sphinx-doc.org/en/master/usage/configuration.html#project-information

project = "matplotloom"
copyright = "2024, Ali Ramadhan"
author = "Ali Ramadhan"
version = matplotloom.__version__
release = matplotloom.__version__

# -- General configuration ---------------------------------------------------
# https://www.sphinx-doc.org/en/master/usage/configuration.html#general-configuration

extensions = [
"sphinx.ext.autodoc",
"sphinx.ext.coverage",
"sphinx.ext.duration",
"sphinx.ext.napoleon"
]

templates_path = ["_templates"]
exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"]

napoleon_google_docstring = False
napoleon_numpy_docstring = True

# -- 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_options = {
"nosidebar": True
}
Loading

0 comments on commit e1fd555

Please sign in to comment.