Download:
child 25:02687e613b7d
parent 23:78c3d66226a4
24:751c2fca6ce6 draft
Anton Shestakov <av6@dwimlabs.net>, Wed, 21 Nov 2018 19:24:01 +0800
plugin: more supybot-esque help for commands

1 файлов изменено, 9 вставок(+), 3 удалений(-) [+]
plugin.py file | annotate | diff | comparison | revisions
--- a/plugin.py Wed Nov 21 18:20:21 2018 +0800
+++ b/plugin.py Wed Nov 21 19:24:01 2018 +0800
@@ -64,7 +64,9 @@
self.hg = Hg(self.path)
def hghelp(self, irc, msg, args, cmd):
- """runs hg help with the given args"""
+ """<topic>
+
+ Runs hg help with the given args."""
def fmt(text):
lines = text.splitlines()
out = []
@@ -115,7 +117,9 @@
def _changelogcmd(repo):
def cmd(self, irc, msg, args, rev):
- """gets the changelog message for the given revision of the repository"""
+ """<revision>
+
+ Returns the changelog message and the URL for the given revision."""
self._changelog(irc, repo, rev)
return wrap(cmd, ['revision'])
@@ -123,7 +127,9 @@
crew = _changelogcmd('/home/brendan/hg/mirror/mercurial/crew')
def glossary(self, irc, msg, args, term):
- """usage: glossary <term>"""
+ """<term>
+
+ Returns glossary definition (from hg help glossary) for the term."""
raw, err = self.hg.run(['help', 'glossary'])
found = False
done = False