Skip to content

Commit 08d5fe4

Browse files
authored
Merge pull request #35 from supabase/j0_add_docs
Add Initial Sphinx Documentation
2 parents 5f7b3bb + b74e439 commit 08d5fe4

File tree

7 files changed

+153
-1
lines changed

7 files changed

+153
-1
lines changed

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
[![Tests](https://github.com/supabase/supabase-py/actions/workflows/ci-python.yml/badge.svg)](https://github.com/supabase/supabase-py/actions)
44
[![PYPI Version](https://badge.fury.io/py/supabase-py.svg)](https://badge.fury.io/py/supabase-py)
5-
[![Documentation Status](https://readthedocs.org/projects/supabase-py/badge/?version=latest)](https://gotrue-py.readthedocs.io/en/latest/?badge=latest)
5+
[![Documentation Status](https://readthedocs.org/projects/supabase/badge/?version=latest)](https://supabase.readthedocs.io/en/latest/?badge=latest)
66

77
Supabase client for Python. This mirrors the design of [supabase-js](https://github.com/supabase/supabase-js/blob/master/README.md)
88

docs/Makefile

+20
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
# Minimal makefile for Sphinx documentation
2+
#
3+
4+
# You can set these variables from the command line, and also
5+
# from the environment for the first two.
6+
SPHINXOPTS ?=
7+
SPHINXBUILD ?= sphinx-build
8+
SOURCEDIR = .
9+
BUILDDIR = _build
10+
11+
# Put it first so that "make" without argument is like "make help".
12+
help:
13+
@$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
14+
15+
.PHONY: help Makefile
16+
17+
# Catch-all target: route all unknown targets to Sphinx using the new
18+
# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
19+
%: Makefile
20+
@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)

docs/conf.py

+51
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
# Configuration file for the Sphinx documentation builder.
2+
#
3+
# This file only contains a selection of the most common options. For a full
4+
# list see the documentation:
5+
# https://www.sphinx-doc.org/en/master/usage/configuration.html
6+
7+
# -- Path setup --------------------------------------------------------------
8+
9+
# If extensions (or modules to document with autodoc) are in another directory,
10+
# add these directories to sys.path here. If the directory is relative to the
11+
# documentation root, use os.path.abspath to make it absolute, like shown here.
12+
#
13+
# import os
14+
# import sys
15+
# sys.path.insert(0, os.path.abspath('.'))
16+
17+
18+
# -- Project information -----------------------------------------------------
19+
20+
project = "supabase"
21+
copyright = "2021, Joel Lee"
22+
author = "Joel Lee"
23+
24+
25+
# -- General configuration ---------------------------------------------------
26+
27+
# Add any Sphinx extension module names here, as strings. They can be
28+
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
29+
# ones.
30+
extensions = ["sphinx.ext.autodoc", "sphinx.ext.napoleon"]
31+
32+
# Add any paths that contain templates here, relative to this directory.
33+
templates_path = ["_templates"]
34+
35+
# List of patterns, relative to source directory, that match files and
36+
# directories to ignore when looking for source files.
37+
# This pattern also affects html_static_path and html_extra_path.
38+
exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"]
39+
40+
41+
# -- Options for HTML output -------------------------------------------------
42+
43+
# The theme to use for HTML and HTML Help pages. See the documentation for
44+
# a list of builtin themes.
45+
#
46+
html_theme = "alabaster"
47+
48+
# Add any paths that contain custom static files (such as style sheets) here,
49+
# relative to this directory. They are copied after the builtin static files,
50+
# so a file named "default.css" will overwrite the builtin "default.css".
51+
html_static_path = ["_static"]

docs/index.rst

+34
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
.. supabase documentation master file, created by
2+
sphinx-quickstart on Wed Jul 21 14:39:24 2021.
3+
You can adapt this file completely to your liking, but it should at least
4+
contain the root `toctree` directive.
5+
6+
Welcome to supabase's documentation!
7+
====================================
8+
9+
.. automodule:: supabase_py
10+
:members:
11+
:show-inheritance:
12+
13+
.. toctree::
14+
:maxdepth: 2
15+
:caption: Contents:
16+
17+
query_builder
18+
storage_bucket
19+
20+
21+
22+
Indices and tables
23+
==================
24+
25+
* :ref:`genindex`
26+
* :ref:`modindex`
27+
* :ref:`search`
28+
29+
30+
Features
31+
--------
32+
* Auth
33+
* Realtime
34+
* Storage

docs/make.bat

+35
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
@ECHO OFF
2+
3+
pushd %~dp0
4+
5+
REM Command file for Sphinx documentation
6+
7+
if "%SPHINXBUILD%" == "" (
8+
set SPHINXBUILD=sphinx-build
9+
)
10+
set SOURCEDIR=.
11+
set BUILDDIR=_build
12+
13+
if "%1" == "" goto help
14+
15+
%SPHINXBUILD% >NUL 2>NUL
16+
if errorlevel 9009 (
17+
echo.
18+
echo.The 'sphinx-build' command was not found. Make sure you have Sphinx
19+
echo.installed, then set the SPHINXBUILD environment variable to point
20+
echo.to the full path of the 'sphinx-build' executable. Alternatively you
21+
echo.may add the Sphinx directory to PATH.
22+
echo.
23+
echo.If you don't have Sphinx installed, grab it from
24+
echo.http://sphinx-doc.org/
25+
exit /b 1
26+
)
27+
28+
%SPHINXBUILD% -M %1 %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O%
29+
goto end
30+
31+
:help
32+
%SPHINXBUILD% -M help %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O%
33+
34+
:end
35+
popd

docs/query_builder.rst

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
Query Builder
2+
================
3+
4+
.. automodule:: supabase_py.lib.query_builder
5+
:members:
6+
:show-inheritance:

docs/storage_bucket.rst

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
Storage Bucket
2+
================
3+
4+
.. automodule:: supabase_py.lib.storage.storage_bucket_api
5+
:members:
6+
:show-inheritance:

0 commit comments

Comments
 (0)