From a996f9356fff0923b775e21733bd35cdf466d75a Mon Sep 17 00:00:00 2001 From: Siddharth Ravikumar Date: Tue, 5 Jan 2016 23:44:23 -0500 Subject: docstrings in combox.cbox are sphinx friendly now. --- combox/cbox.py | 21 +++++++++++++++++---- 1 file changed, 17 insertions(+), 4 deletions(-) (limited to 'combox') diff --git a/combox/cbox.py b/combox/cbox.py index e8d08a3..2e29f70 100644 --- a/combox/cbox.py +++ b/combox/cbox.py @@ -40,8 +40,20 @@ from combox.log import log_i, log_e ## http://pythonhosted.org/watchdog/quickstart.html#quickstart def run_cb(config): - """ - Runs combox. + """Runs combox. + + - Creates an instance of :class:`.ComboxDirMonitor` to monitor the + combox directory. + + - Creates an instance of :class:`.NodeDirMonitor` for each node + directory. + + Exits on Ctrt-C. + + :param dict config: + A dictionary that contains configuration information about + combox. + """ db_lock = Lock() monitor_lock = Lock() @@ -87,9 +99,10 @@ def run_cb(config): log_i("combox exiting. Bye!") + def main(): - """ - Main functions, parses args and calls run_cb() + """Parses args; starts combox configuration if necessary; starts combox. + """ parser = ArgumentParser() parser.add_argument("-t", "--test", -- cgit v1.2.3