nemubot/nemubot
nemunaire 4cb8b0f1a6 Improve help
On hook declaration, we can now add a help and/or a help_usage argument
	to provide a simple way to the user to be informed.

	For example:

	```python
	@hook("cmd_hook", "news", help_usage={"URL": "Display the latests news from a given URL"})
	def cmd_news(msg):
	    [...]
	```

	will be displayed on !help !news as:

	> Usage for command !news from module news: !news URL: Display the latests news from a given URL

	Or for module commands help:

	```python
	@hook("cmd_hook", "news", help="display latests news")
	def cmd_news(msg):
	    [...]
	```

	will be displayed on !help mymodule (assuming this hook is in the
	module named mymodule) as:

	> Available commands for module news: news: display latests news

	Obviously, both `help` and `help_usage` can be present. If `help_usage`
	doesn't exist, help on usage will display the content of help.
2015-09-24 11:29:51 +02:00
..
datastore XML datastore: load will now automatically try to load backup 2015-06-24 20:06:00 +02:00
event Place events to a separate directory 2015-05-25 16:44:25 +02:00
hooks Improve help 2015-09-24 11:29:51 +02:00
message Allow socket to print messages 2015-08-26 12:18:23 +02:00
prompt Optimize imports 2015-05-25 16:44:16 +02:00
server Allow socket to print messages 2015-08-26 12:18:23 +02:00
tools tools.web: don't try to striphtml content that is not str or buffer 2015-09-24 11:29:47 +02:00
__init__.py Doc 2015-05-25 16:44:27 +02:00
__main__.py Datastore: add a method to create a new empty tree 2015-05-25 16:44:26 +02:00
bot.py Improve help 2015-09-24 11:29:51 +02:00
channel.py [wip] changes import to reflect new directory structure 2015-01-05 02:48:49 +01:00
consumer.py Display a basic error to IM user on uncatched exception 2015-09-24 11:29:47 +02:00
exception.py Split messages class into multiple files 2015-05-25 16:44:27 +02:00
importer.py Catch exception during module loading: just skip the module registration 2015-06-03 18:01:50 +02:00
modulecontext.py New function in ModuleContext: call_hook 2015-06-24 20:05:54 +02:00