# }
html_theme = 'alabaster'
html_theme_options = {
- 'donate_url': 'https://liberapay.com/kaliko/'
+ 'donate_url': 'https://liberapay.com/kaliko/',
+ 'style_external_links': True,
}
html_show_sphinx = False
:undoc-members:
.. vim: spell spelllang=en
+
+
+Available plugins
+-----------------
+
+Generic plugins
+~~~~~~~~~~~~~~~
+
+.. automodule:: sid.echo
+ :members:
+ :show-inheritance:
+
+.. autoclass:: sid.feeds.Feeds
+ :members:
+ :show-inheritance:
+
+.. automodule:: sid.log
+ :members:
+ :show-inheritance:
+
+.. autoclass:: sid.rtbl.RTBL
+ :members:
+ :show-inheritance:
+
+Debian plugins
+~~~~~~~~~~~~~~
+
+.. automodule:: sid.archive
+ :members:
+ :show-inheritance:
+
+.. automodule:: sid.bts
+ :members:
+ :show-inheritance:
+
+.. vim: spell spelllang=en
sphinx-quickstart on Tue May 5 12:46:38 2020.
You can adapt this file completely to your liking, but it should at least
contain the root `toctree` directive.
+.. _home:
.. include:: ../../README.rst
:maxdepth: 2
:caption: Contents:
+ self
rtbl.rst
- doc.rst
plugins.rst
+ doc.rst
contribute.rst
Indices and tables
-Available plugins
-=================
-
Generic plugins
----------------
+===============
-.. automodule:: sid.echo
- :members:
- :show-inheritance:
+This page documents plugin import usage only.
-.. autoclass:: sid.feeds.Feeds
- :members:
- :show-inheritance:
+Real time block list
+--------------------
+.. automodule:: sid.rtbl
+ :noindex:
-.. automodule:: sid.log
- :members:
- :show-inheritance:
+Feeds
+-----
+.. automodule:: sid.feeds
+ :noindex:
-.. autoclass:: sid.rtbl.RTBL
- :members:
- :show-inheritance:
Debian plugins
---------------
+==============
+Archive
+-------
.. automodule:: sid.archive
- :members:
- :show-inheritance:
+ :noindex:
+Bugs
+----
.. automodule:: sid.bts
- :members:
- :show-inheritance:
-
-
-.. vim: spell spelllang=en
+ :noindex:
# -*- coding: utf-8 -*-
# SPDX-FileCopyrightText: 2020 kaliko <kaliko@azylum.org>
# SPDX-License-Identifier: GPL-3.0-or-later
+"""Fetch packages info from the archive
+
+>>> from sid.archive import Archive
+"""
from re import compile as re_compile
# SPDX-FileCopyrightText: 2015, 2021 kaliko <kaliko@azylum.org>
# SPDX-FileCopyrightText: 2010, 2011 Anaƫl Verrier <elghinn@free.fr>
# SPDX-License-Identifier: GPL-3.0-or-later
+"""Intercepts bugs numbers in MUC messages and send info about it
+
+>>> from sid.bts import Bugs
+"""
from re import compile as re_compile
# -*- coding: utf-8 -*-
# SPDX-FileCopyrightText: 2011, 2014, 2020 kaliko <kaliko@azylum.org>
# SPDX-License-Identifier: GPL-3.0-or-later
+"""Publish news from various Debian feeds (security, planet, package tracker, see :py:obj:`sid.feeds.Feeds.FEEDS` for defaults).
+
+Can easily be used for other feeds (rss, atom).
+
+.. note::
+ Feeds plugin depends on external module: **feedparser**
+
+>>> from sid.feeds import Feeds
+>>> # Time between check in seconds
+>>> Feeds.TEMPO = 60
+>>> # Fedds to monitor, cf. sid.feeds.Feeds.FEEDS for defaults
+>>> Feeds.FEEDS = [
+ 'https://example.org/feeds/atom/news.atom.xml'
+ ]
+"""
import datetime
import threading
# -*- coding: utf-8 -*-
# SPDX-FileCopyrightText: 2023 kaliko <kaliko@azylum.org>
# SPDX-License-Identifier: GPL-3.0-or-later
-"""A Real Time Block List plugin"""
+"""A Real Time Block List plugin, cf https://xmppbl.org.
+
+>>> from sid.rtbl import RTBL, BL
+>>> RTBL.pubsub_server = 'xmppbl.org'
+>>> # Optional: Node to subcribe, defaults to 'muc_bans_sha256'
+>>> RTBL.node = 'muc_bans_sha256'
+>>> # Optional: Add this JID hash to the list, default is empty, usefull for test
+>>> BL.init = {'1312b8ca593cd074f39ef15cc8442cdf426b21480958836d9ab678ca45ed1312': 'Test!'}
+>>> # Optional: Set plugin log level, default inherit from the bot
+>>> RTBL.log_level = logging.DEBUG
+"""
from hashlib import sha256
from typing import Dict, Optional