mirror of
https://github.com/eternnoir/pyTelegramBotAPI.git
synced 2023-08-10 21:12:57 +03:00
Merge pull request #1458 from coder2020official/master
Bump documentation
This commit is contained in:
commit
9ecadf1bc1
5
.gitignore
vendored
5
.gitignore
vendored
@ -64,3 +64,8 @@ testMain.py
|
||||
#VS Code
|
||||
.vscode/
|
||||
.DS_Store
|
||||
|
||||
# documentation
|
||||
_build/
|
||||
_static/
|
||||
_templates/
|
||||
|
19
.readthedocs.yml
Normal file
19
.readthedocs.yml
Normal file
@ -0,0 +1,19 @@
|
||||
# .readthedocs.yml
|
||||
# Read the Docs configuration file
|
||||
# See https://docs.readthedocs.io/en/stable/config-file/v2.html for details
|
||||
|
||||
# Required
|
||||
version: 2
|
||||
|
||||
# Build documentation in the docs/ directory with Sphinx
|
||||
sphinx:
|
||||
configuration: docs/source/conf.py
|
||||
|
||||
# Optionally build your docs in additional formats such as PDF and ePub
|
||||
formats: all
|
||||
|
||||
# Optionally set the version of Python and requirements required to build your docs
|
||||
python:
|
||||
version: 3.7
|
||||
install:
|
||||
- requirements: doc_req.txt
|
1
doc_req.txt
Normal file
1
doc_req.txt
Normal file
@ -0,0 +1 @@
|
||||
pytelegrambotapi
|
20
docs/Makefile
Normal file
20
docs/Makefile
Normal file
@ -0,0 +1,20 @@
|
||||
# Minimal makefile for Sphinx documentation
|
||||
#
|
||||
|
||||
# You can set these variables from the command line, and also
|
||||
# from the environment for the first two.
|
||||
SPHINXOPTS ?=
|
||||
SPHINXBUILD ?= sphinx-build
|
||||
SOURCEDIR = source
|
||||
BUILDDIR = build
|
||||
|
||||
# Put it first so that "make" without argument is like "make help".
|
||||
help:
|
||||
@$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
|
||||
|
||||
.PHONY: help Makefile
|
||||
|
||||
# Catch-all target: route all unknown targets to Sphinx using the new
|
||||
# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
|
||||
%: Makefile
|
||||
@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
|
51
docs/source/async_version/index.rst
Normal file
51
docs/source/async_version/index.rst
Normal file
@ -0,0 +1,51 @@
|
||||
====================
|
||||
AsyncTeleBot
|
||||
====================
|
||||
|
||||
AsyncTeleBot methods
|
||||
--------------------
|
||||
|
||||
.. automodule:: telebot.async_telebot
|
||||
:members:
|
||||
:undoc-members:
|
||||
:show-inheritance:
|
||||
|
||||
|
||||
|
||||
Asyncio filters
|
||||
---------------
|
||||
|
||||
.. automodule:: telebot.asyncio_filters
|
||||
:members:
|
||||
:undoc-members:
|
||||
:show-inheritance:
|
||||
|
||||
Asynchronous storage for states
|
||||
-------------------------------
|
||||
|
||||
.. automodule:: telebot.asyncio_storage
|
||||
:members:
|
||||
:undoc-members:
|
||||
:show-inheritance:
|
||||
|
||||
asyncio_helper file
|
||||
-------------------
|
||||
|
||||
.. automodule:: telebot.asyncio_helper
|
||||
:members:
|
||||
:undoc-members:
|
||||
:show-inheritance:
|
||||
|
||||
|
||||
Asyncio handler backends
|
||||
------------------------
|
||||
|
||||
|
||||
|
||||
.. automodule:: telebot.asyncio_handler_backends
|
||||
:members:
|
||||
:undoc-members:
|
||||
:show-inheritance:
|
||||
|
||||
|
||||
|
13
docs/source/calldata.rst
Normal file
13
docs/source/calldata.rst
Normal file
@ -0,0 +1,13 @@
|
||||
|
||||
=====================
|
||||
Callback data factory
|
||||
=====================
|
||||
|
||||
|
||||
callback\_data file
|
||||
-----------------------------
|
||||
|
||||
.. automodule:: telebot.callback_data
|
||||
:members:
|
||||
:undoc-members:
|
||||
:show-inheritance:
|
66
docs/source/conf.py
Normal file
66
docs/source/conf.py
Normal file
@ -0,0 +1,66 @@
|
||||
# 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 = 'pyTelegramBotAPI'
|
||||
copyright = '2022, coder2020official'
|
||||
author = 'coder2020official'
|
||||
|
||||
# The full version, including alpha/beta/rc tags
|
||||
release = '1.0'
|
||||
|
||||
|
||||
# -- 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_rtd_theme',
|
||||
'sphinx.ext.autosectionlabel',
|
||||
'sphinx.ext.autodoc',
|
||||
"sphinx.ext.autosummary",
|
||||
"sphinx.ext.napoleon",
|
||||
|
||||
]
|
||||
|
||||
# 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 = []
|
||||
|
||||
|
||||
# -- 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']
|
||||
html_logo = 'logo.png'
|
||||
html_theme_options = {
|
||||
'logo_only': True,
|
||||
'display_version': False,
|
||||
}
|
63
docs/source/index.rst
Normal file
63
docs/source/index.rst
Normal file
@ -0,0 +1,63 @@
|
||||
.. pyTelegramBotAPI documentation master file, created by
|
||||
sphinx-quickstart on Fri Feb 18 20:58:37 2022.
|
||||
You can adapt this file completely to your liking, but it should at least
|
||||
contain the root `toctree` directive.
|
||||
|
||||
|
||||
Welcome to pyTelegramBotAPI's documentation!
|
||||
============================================
|
||||
|
||||
=======
|
||||
TeleBot
|
||||
=======
|
||||
TeleBot is synchronous and asynchronous implementation of `Telegram Bot API <https://core.telegram.org/bots/api>`_.
|
||||
|
||||
Chats
|
||||
-----
|
||||
English chat: `Private chat <https://telegram.me/joinchat/Bn4ixj84FIZVkwhk2jag6A>`__
|
||||
|
||||
Russian chat: `@pytelegrambotapi_talks_ru <https://t.me/pytelegrambotapi_talks_ru>`__
|
||||
|
||||
News: `@pyTelegramBotAPI <https://t.me/pytelegrambotapi>`__
|
||||
|
||||
Pypi: `Pypi <https://pypi.org/project/pyTelegramBotAPI/>`__
|
||||
|
||||
Source: `Github repository <https://github.com/eternnoir/pyTelegramBotAPI>`__
|
||||
|
||||
Some features:
|
||||
-------------
|
||||
Easy to learn and use.
|
||||
|
||||
Easy to understand.
|
||||
|
||||
Both sync and async.
|
||||
|
||||
Examples on features.
|
||||
|
||||
States
|
||||
|
||||
And more...
|
||||
|
||||
Content
|
||||
--------
|
||||
.. toctree::
|
||||
|
||||
install
|
||||
quick_start
|
||||
types
|
||||
sync_version/index
|
||||
async_version/index
|
||||
calldata
|
||||
util
|
||||
|
||||
|
||||
|
||||
|
||||
Indices and tables
|
||||
==================
|
||||
|
||||
* :ref:`genindex`
|
||||
* :ref:`modindex`
|
||||
* :ref:`search`
|
||||
|
||||
|
41
docs/source/install.rst
Normal file
41
docs/source/install.rst
Normal file
@ -0,0 +1,41 @@
|
||||
==================
|
||||
Installation Guide
|
||||
==================
|
||||
|
||||
|
||||
:toctree
|
||||
|
||||
Using PIP
|
||||
----------
|
||||
.. code-block:: bash
|
||||
|
||||
$ pip install pyTelegramBotAPI
|
||||
|
||||
Using pipenv
|
||||
------------
|
||||
.. code-block:: bash
|
||||
|
||||
$ pipenv install pyTelegramBotAPI
|
||||
|
||||
By cloning repository
|
||||
---------------------
|
||||
.. code-block:: bash
|
||||
|
||||
$ git clone https://github.com/eternnoir/pyTelegramBotAPI.git
|
||||
$ cd pyTelegramBotAPI
|
||||
$ python setup.py install
|
||||
|
||||
Directly using pip
|
||||
------------------
|
||||
.. code-block:: bash
|
||||
$ pip install git+https://github.com/eternnoir/pyTelegramBotAPI.git
|
||||
|
||||
It is generally recommended to use the first option.
|
||||
|
||||
While the API is production-ready, it is still under development and it has regular updates, do not forget to update it regularly by calling:
|
||||
|
||||
.. code-block:: bash
|
||||
|
||||
$ pip install pytelegrambotapi --upgrade
|
||||
|
||||
|
BIN
docs/source/logo.png
Normal file
BIN
docs/source/logo.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 57 KiB |
16
docs/source/quick_start.rst
Normal file
16
docs/source/quick_start.rst
Normal file
@ -0,0 +1,16 @@
|
||||
|
||||
===========
|
||||
Quick start
|
||||
===========
|
||||
|
||||
Synchronous TeleBot
|
||||
-------------------
|
||||
.. literalinclude:: ../examples/echo_bot.py
|
||||
:language: python
|
||||
|
||||
Asynchronous TeleBot
|
||||
--------------------
|
||||
.. literalinclude:: ../examples/asynchronous_telebot/echo_bot.py
|
||||
:language: python
|
||||
|
||||
|
43
docs/source/sync_version/index.rst
Normal file
43
docs/source/sync_version/index.rst
Normal file
@ -0,0 +1,43 @@
|
||||
===============
|
||||
TeleBot version
|
||||
===============
|
||||
|
||||
TeleBot methods
|
||||
---------------
|
||||
.. automodule:: telebot
|
||||
:members:
|
||||
:undoc-members:
|
||||
:show-inheritance:
|
||||
|
||||
custom_filters file
|
||||
------------------------------
|
||||
|
||||
.. automodule:: telebot.custom_filters
|
||||
:members:
|
||||
:undoc-members:
|
||||
:show-inheritance:
|
||||
|
||||
Synchronous storage for states
|
||||
-------------------------------
|
||||
|
||||
.. automodule:: telebot.storage
|
||||
:members:
|
||||
:undoc-members:
|
||||
:show-inheritance:
|
||||
|
||||
handler_backends file
|
||||
--------------------------------
|
||||
|
||||
.. automodule:: telebot.handler_backends
|
||||
:members:
|
||||
:undoc-members:
|
||||
:show-inheritance:
|
||||
|
||||
apihelper
|
||||
------------------------
|
||||
|
||||
.. automodule:: telebot.apihelper
|
||||
:members:
|
||||
:undoc-members:
|
||||
:show-inheritance:
|
||||
|
10
docs/source/types.rst
Normal file
10
docs/source/types.rst
Normal file
@ -0,0 +1,10 @@
|
||||
============
|
||||
Types of API
|
||||
============
|
||||
|
||||
|
||||
|
||||
.. automodule:: telebot.types
|
||||
:members:
|
||||
:undoc-members:
|
||||
:show-inheritance:
|
12
docs/source/util.rst
Normal file
12
docs/source/util.rst
Normal file
@ -0,0 +1,12 @@
|
||||
============
|
||||
Utils
|
||||
============
|
||||
|
||||
|
||||
util file
|
||||
-------------------
|
||||
|
||||
.. automodule:: telebot.util
|
||||
:members:
|
||||
:undoc-members:
|
||||
:show-inheritance:
|
Loading…
Reference in New Issue
Block a user