Document more things, finalize docs file structure
This commit is contained in:
parent
41eb244d25
commit
f9581e207e
|
@ -0,0 +1,10 @@
|
|||
:mod:`ModuleBase` --- Main class of the bot
|
||||
=========================================
|
||||
|
||||
yabba blahblah blahblah
|
||||
|
||||
.. automodule:: core.modulebase
|
||||
:members:
|
||||
:undoc-members:
|
||||
:show-inheritance:
|
||||
|
|
@ -0,0 +1,9 @@
|
|||
:mod:`Error` --- A module to cause an error
|
||||
===========================================
|
||||
|
||||
yabba blahblah blahblah
|
||||
|
||||
.. automodule:: modules.Error
|
||||
:members:
|
||||
:undoc-members:
|
||||
:show-inheritance:
|
|
@ -0,0 +1,9 @@
|
|||
:mod:`Scramble` --- Module to provide a word scramble game
|
||||
=========================================================
|
||||
|
||||
yabba blahblah blahblah
|
||||
|
||||
.. automodule:: modules.Scramble
|
||||
:members:
|
||||
:undoc-members:
|
||||
:show-inheritance:
|
|
@ -7,3 +7,4 @@ yabba blahblah blahblah
|
|||
:members:
|
||||
:undoc-members:
|
||||
:show-inheritance:
|
||||
|
|
@ -0,0 +1,9 @@
|
|||
:mod:`BotRPC` --- Main class of the bot
|
||||
=========================================
|
||||
|
||||
yabba blahblah blahblah
|
||||
|
||||
.. automodule:: core.rpc
|
||||
:members:
|
||||
:undoc-members:
|
||||
:show-inheritance:
|
|
@ -22,6 +22,9 @@ import os
|
|||
#sys.path.insert(0, os.path.abspath('.'))
|
||||
sys.path.insert(0, os.path.abspath('../pyircbot/'))
|
||||
|
||||
sys.path.append(os.path.abspath('../pyircbot/core/'))
|
||||
sys.path.append(os.path.abspath('../pyircbot/modules/'))
|
||||
|
||||
# -- General configuration ------------------------------------------------
|
||||
|
||||
# If your documentation needs a minimal Sphinx version, state it here.
|
||||
|
@ -60,7 +63,8 @@ copyright = '2014, dpedu'
|
|||
# The short X.Y version.
|
||||
version = '3.4'
|
||||
# The full version, including alpha/beta/rc tags.
|
||||
release = '1.0a1'
|
||||
import pyircbot
|
||||
release = pyircbot.PyIRCBot.version
|
||||
|
||||
# The language for content autogenerated by Sphinx. Refer to documentation
|
||||
# for a list of supported languages.
|
||||
|
|
|
@ -18,7 +18,6 @@ Contents:
|
|||
modules/_modules.rst
|
||||
rpc/_rpc.rst
|
||||
dev/_dev.rst
|
||||
#PyIRCBot.rst
|
||||
|
||||
More Information
|
||||
================
|
||||
|
|
|
@ -1,4 +1,12 @@
|
|||
Included Modules
|
||||
================
|
||||
|
||||
TODO: Document included modules
|
||||
PyIRCBot includes several modules to add basic functionality to your bot.
|
||||
|
||||
Contents:
|
||||
|
||||
.. toctree::
|
||||
:maxdepth: 8
|
||||
:glob:
|
||||
|
||||
../api/modules/*
|
||||
|
|
|
@ -0,0 +1,11 @@
|
|||
"""
|
||||
.. module:: Core
|
||||
:synopsis: Core module of the bot
|
||||
|
||||
.. moduleauthor:: Dave Pedu <dave@davepedu.com>
|
||||
|
||||
.. automodule:: core.pyircbot
|
||||
|
||||
.. automodule:: core.rpc
|
||||
|
||||
"""
|
|
@ -1,4 +1,10 @@
|
|||
#!/usr/bin/env python
|
||||
"""
|
||||
.. module:: ModuleBase
|
||||
:synopsis: Base class that modules will extend
|
||||
|
||||
.. moduleauthor:: Dave Pedu <dave@davepedu.com>
|
||||
|
||||
"""
|
||||
|
||||
import logging
|
||||
import os
|
||||
|
|
|
@ -28,6 +28,8 @@ class PyIRCBot(asynchat.async_chat):
|
|||
:type botconfig: dict
|
||||
"""
|
||||
|
||||
version = "1.0a1-git"
|
||||
|
||||
def __init__(self, coreconfig, botconfig):
|
||||
asynchat.async_chat.__init__(self)
|
||||
|
||||
|
|
|
@ -1,4 +1,11 @@
|
|||
#!/usr/bin/env python
|
||||
"""
|
||||
.. module:: BotRPC
|
||||
:synopsis: RPC server
|
||||
|
||||
.. moduleauthor:: Dave Pedu <dave@davepedu.com>
|
||||
|
||||
"""
|
||||
|
||||
import traceback
|
||||
import logging
|
||||
from core import jsonrpc
|
||||
|
|
|
@ -1,3 +1,11 @@
|
|||
"""
|
||||
.. module:: Error
|
||||
:synopsis: Module to deliberately cause an error for testing handling.
|
||||
|
||||
.. moduleauthor:: Dave Pedu <dave@davepedu.com>
|
||||
|
||||
"""
|
||||
|
||||
#!/usr/bin/env python
|
||||
from modulebase import ModuleBase,ModuleHook
|
||||
|
||||
|
|
|
@ -1,4 +1,11 @@
|
|||
#!/usr/bin/env python
|
||||
"""
|
||||
.. module:: Scramble
|
||||
:synopsis: Module to provide a word scramble game
|
||||
|
||||
.. moduleauthor:: Dave Pedu <dave@davepedu.com>
|
||||
|
||||
"""
|
||||
|
||||
from modulebase import ModuleBase,ModuleHook
|
||||
import random
|
||||
import yaml
|
||||
|
@ -16,7 +23,7 @@ class Scramble(ModuleBase):
|
|||
|
||||
# Dictionary
|
||||
self.wordsCount=0;
|
||||
self.wordsFile = self.getFilePath("words.txt")
|
||||
self.wordsFile = self.getFilePath("words.txt")
|
||||
print(self.wordsFile)
|
||||
wordsF = open(self.wordsFile, "r")
|
||||
while True:
|
||||
|
|
|
@ -0,0 +1,7 @@
|
|||
"""
|
||||
.. module:: Modules
|
||||
:synopsis: Module containing the bot's modules
|
||||
|
||||
.. moduleauthor:: Dave Pedu <dave@davepedu.com>
|
||||
|
||||
"""
|
Loading…
Reference in New Issue