]> kaliko git repositories - sid.git/blobdiff - sid/echo.py
sphinx: document plugins
[sid.git] / sid / echo.py
index 90ccd900dfc42ff9a2956d21b6220cd547a1a513..5bb90c06768e7e5daaf9e99b6721ef8d3a352784 100644 (file)
@@ -19,7 +19,7 @@ from .plugin import Plugin, botcmd
 
 
 class Echo(Plugin):
-    """Drop a message to be sent when someone gets online.
+    """Drops a message to be sent when someone gets online.
     """
 
     def __init__(self, bot):
@@ -35,7 +35,7 @@ class Echo(Plugin):
                               self.bot.room, self.log_presence)
 
     def log_presence(self, pres):
-        """Register presence"""
+        """Handler method registering MUC participants presence"""
         self.log.debug('%s: %s', pres['muc']['nick'], pres['type'])
         nick = pres['muc']['nick']
         self.presence.update({nick: (pres['muc']['role'], pres['type'])})
@@ -49,9 +49,11 @@ class Echo(Plugin):
 
     @botcmd
     def tell(self, message, args):
-        """drop a message to be sent when someone gets online.
-        !tell queue        : messages in queue
-        !tell <nick> <msg> : append <msg> to <nick> in queue"""
+        """
+        **commands**:
+
+        * ``!tell queue``        : messages in queue
+        * ``!tell <nick> <msg>`` : append <msg> to <nick> in queue"""
         if not len(args):
             msg = 'Missing arguments:\n{}'.format(self.tell.__doc__)
             self.reply(message, msg)