Skip to content

Commit 052e508

Browse files
adds docs.
1 parent 482c926 commit 052e508

File tree

15 files changed

+201
-2
lines changed

15 files changed

+201
-2
lines changed

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
11
dist
2+
docs/_build
3+
.coverage
24
.pytest_cache
35
.venv

docs/Makefile

Lines changed: 20 additions & 0 deletions
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/api/base.rst

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
Base
2+
====
3+
4+
.. automodule:: base
5+
:members:

docs/api/files.rst

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
Files
2+
=====
3+
4+
.. automodule:: files
5+
:members:

docs/api/index.rst

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
Programming Interface
2+
=====================
3+
4+
.. toctree::
5+
:maxdepth: 1
6+
:caption: Contents:
7+
8+
9+
base
10+
files
11+
schedule
12+
webapp

docs/api/schedule.rst

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
Scheduled Tasks
2+
===============
3+
4+
.. automodule:: schedule
5+
:members:

docs/api/webapp.rst

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
Web Apps
2+
========
3+
4+
.. automodule:: webapp
5+
:members:

docs/conf.py

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
# Configuration file for the Sphinx documentation builder.
2+
#
3+
# For the full list of built-in configuration values, see the documentation:
4+
# https://www.sphinx-doc.org/en/master/usage/configuration.html
5+
6+
# -- Project information -----------------------------------------------------
7+
# https://www.sphinx-doc.org/en/master/usage/configuration.html#project-information
8+
9+
import os
10+
import sys
11+
sys.path.insert(0, os.path.abspath('../pythonanywhere_core'))
12+
13+
project = 'pythonanywhere-core'
14+
copyright = '2024, PythonAnywhere'
15+
author = 'PythonAnywhere'
16+
17+
# -- General configuration ---------------------------------------------------
18+
# https://www.sphinx-doc.org/en/master/usage/configuration.html#general-configuration
19+
20+
extensions = ["sphinx.ext.autodoc",]
21+
22+
templates_path = ['_templates']
23+
exclude_patterns = ['_build', 'Thumbs.db', '.DS_Store']
24+
25+
26+
27+
# -- Options for HTML output -------------------------------------------------
28+
# https://www.sphinx-doc.org/en/master/usage/configuration.html#options-for-html-output
29+
30+
html_theme = 'sphinx_rtd_theme'
31+
html_static_path = ['_static']

docs/index.rst

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
API wrapper for programmatic management of PythonAnywhere services.
2+
3+
It's an extraction and improvement of core code behind `PythonAnywhere cli tool`_.
4+
5+
.. _PythonAnywhere cli tool: https://pypi.org/project/pythonanywhere/
6+
7+
8+
.. toctree::
9+
:maxdepth: 2
10+
:caption: Contents:
11+
12+
13+
installation
14+
api/index
15+
16+
Indices and tables
17+
==================
18+
19+
* :ref:`genindex`
20+
* :ref:`modindex`

docs/installation.rst

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
Installation
2+
============
3+
4+
``$ pip install pythonanywhere-core``

0 commit comments

Comments
 (0)