-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Setup Subete for ReadTheDocs Documentation (#2)
* Mimicked SnakeMD setup.py * Added conf.py and index.rst for docs * Added logos * Updated index homepage * Setup automodule
- Loading branch information
Showing
8 changed files
with
138 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -112,3 +112,7 @@ dmypy.json | |
|
||
# Pyre type checker | ||
.pyre/ | ||
|
||
# Sphinx | ||
dirhtml/ | ||
doctrees/ |
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
# Configuration file for the Sphinx documentation builder. | ||
# | ||
# This file only contains a selection of the most common options. For a full | ||
# list see the documentation: | ||
# https://www.sphinx-doc.org/en/master/usage/configuration.html | ||
|
||
# -- Path setup -------------------------------------------------------------- | ||
|
||
# If extensions (or modules to document with autodoc) are in another directory, | ||
# add these directories to sys.path here. If the directory is relative to the | ||
# documentation root, use os.path.abspath to make it absolute, like shown here. | ||
# | ||
import os | ||
import sys | ||
sys.path.insert(0, os.path.abspath('../')) | ||
|
||
|
||
# -- Project information ----------------------------------------------------- | ||
|
||
project = 'subete' | ||
copyright = '2021, The Renegade Coder' | ||
author = 'The Renegade Coder' | ||
|
||
# -- General configuration --------------------------------------------------- | ||
|
||
# Add any Sphinx extension module names here, as strings. They can be | ||
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom | ||
# ones. | ||
extensions = ['sphinx.ext.autodoc', "sphinx_issues"] | ||
|
||
# Add any paths that contain templates here, relative to this directory. | ||
templates_path = ['_templates'] | ||
|
||
# List of patterns, relative to source directory, that match files and | ||
# directories to ignore when looking for source files. | ||
# This pattern also affects html_static_path and html_extra_path. | ||
exclude_patterns = ['_build', 'Thumbs.db', '.DS_Store'] | ||
|
||
|
||
# -- Options for HTML output ------------------------------------------------- | ||
|
||
# The theme to use for HTML and HTML Help pages. See the documentation for | ||
# a list of builtin themes. | ||
# | ||
html_theme = 'sphinx_rtd_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, | ||
# so a file named "default.css" will overwrite the builtin "default.css". | ||
html_static_path = ['_static'] | ||
|
||
github_url = "https://github.com/TheRenegadeCoder/subete" | ||
html_logo = "_static/icon.png" | ||
html_favicon = '_static/favicon.ico' | ||
issues_github_path = "TheRenegadeCoder/subete" | ||
|
||
html_theme_options = { | ||
"display_version": True | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
Welcome to subete's Documentation! | ||
=================================== | ||
|
||
Subete is a library for interacting with the code found | ||
in the Sample Programs repository. Use the links below to | ||
navigate the docs. | ||
|
||
.. toctree:: | ||
:maxdepth: 1 | ||
|
||
subete | ||
|
||
Indices and tables | ||
================== | ||
|
||
* :ref:`genindex` | ||
* :ref:`modindex` | ||
* :ref:`search` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
Documentation | ||
============= | ||
|
||
The documentation page lists out all of the relevant classes | ||
and functions for generating markdown documents in Python. | ||
|
||
subete | ||
------------------- | ||
|
||
The subete module contains all the classes need to represent the Sample Programs repo. | ||
This module was designed with the intent of creating read-only objects that fully | ||
represent the underlying repo. Ideally, classes that make use of these objects | ||
should not need to know how they were generated. For example, we do not want users | ||
to poke around the source directory that was used to generate these files. As a result, | ||
users should make use of the public fields only. | ||
|
||
.. automodule:: subete.repo | ||
:members: | ||
:undoc-members: | ||
:show-inheritance: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,21 +1,48 @@ | ||
import setuptools | ||
|
||
cmdclass = {} | ||
|
||
try: | ||
from sphinx.setup_command import BuildDoc | ||
cmdclass['build_sphinx'] = BuildDoc | ||
except ImportError: | ||
print("WARNING: sphinx not available") | ||
|
||
with open("README.md", "r") as fh: | ||
long_description = fh.read() | ||
|
||
MAJOR = 0 | ||
MINOR = 2 | ||
PATCH = 0 | ||
|
||
name = "subete" | ||
version = f"{MAJOR}.{MINOR}" | ||
release = f"{MAJOR}.{MINOR}.{PATCH}" | ||
setuptools.setup( | ||
name="subete", | ||
version="0.1.0", | ||
name=name, | ||
version=release, | ||
author="The Renegade Coder", | ||
author_email="[email protected]", | ||
description="The Sample Programs API", | ||
long_description=long_description, | ||
long_description_content_type="text/markdown", | ||
url="https://github.com/TheRenegadeCoder/subete", | ||
packages=setuptools.find_packages(), | ||
install_requires=[], | ||
classifiers=( | ||
install_requires=[ | ||
], | ||
classifiers=[ | ||
"Programming Language :: Python :: 3", | ||
"Operating System :: OS Independent", | ||
), | ||
], | ||
cmdclass=cmdclass, | ||
command_options={ | ||
'build_sphinx': { | ||
'project': ('setup.py', name), | ||
'version': ('setup.py', version), | ||
'release': ('setup.py', release), | ||
'source_dir': ('setup.py', 'docs'), | ||
'build_dir': ('setup.py', 'docs'), | ||
'builder': ("setup.py", "dirhtml") | ||
} | ||
} | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters