From f5ad601a08fd5e1a8a9f16816b042129370e4781 Mon Sep 17 00:00:00 2001 From: Mallory Hancock Date: Wed, 10 Jan 2018 14:42:55 -0800 Subject: [PATCH] update readmes --- README.md | 2 ++ README.rst | 3 +++ 2 files changed, 5 insertions(+) diff --git a/README.md b/README.md index 56f9713..8c40f1a 100644 --- a/README.md +++ b/README.md @@ -27,6 +27,7 @@ Optional arguments are: * `port`: choose a custom port to connect to the server (default: 6667) * `ops`: list of operators who can do things like make the bot join other channels or quit (default: empty list) * `plugin_dir`: directory where the bot should look for plugins (default: "plugins") +* `log_level`: string indicating logging level. Logging can be disabled by setting this to "off". (default: "info") ### Creating plugins In your chosen plugins directory ("plugins" by default) make a python file with a function. You can use the `@pinhook.plugin.register` decorator to tell the bot the command to activate the function. @@ -50,6 +51,7 @@ The `Message` object has the following attributes: * `channel`: the channel where the command was initiated * `ops`: the list of bot operators * `botnick`: the nickname of the bot +* `logger`: instance of `Bot`'s logger The plugin function **must** return one of the following in order to give a response to the command: * `pinhook.plugin.message`: basic message in channel where command was triggered diff --git a/README.rst b/README.rst index ce9aa54..d5163bc 100644 --- a/README.rst +++ b/README.rst @@ -40,6 +40,8 @@ Optional arguments are: other channels or quit (default: empty list) - ``plugin_dir``: directory where the bot should look for plugins (default: "plugins") +- ``log_level``: string indicating logging level. Logging can be + disabled by setting this to "off". (default: "info") Creating plugins ~~~~~~~~~~~~~~~~ @@ -71,6 +73,7 @@ The ``Message`` object has the following attributes: - ``channel``: the channel where the command was initiated - ``ops``: the list of bot operators - ``botnick``: the nickname of the bot +- ``logger``: instance of ``Bot``'s logger The plugin function **must** return one of the following in order to give a response to the command: