Make 'meetingname' a required argument of startmeeting.

The meetingname can be used in the filename of the meeting logs.

Change-Id: I8a72f292a6a995e517114350373507c20ca4ce7e
This commit is contained in:
James E. Blair 2012-08-21 21:15:30 +00:00
parent 620ed19d2e
commit 9254a4ae1e
2 changed files with 5 additions and 1 deletions

View File

@ -94,6 +94,10 @@ class MeetBot(callbacks.Plugin):
if M is not None:
irc.error("Can't start another meeting, one is in progress.")
return
name = payload[13:].strip()
if not name:
irc.error("A meeting name is required, e.g., '#startmeeting Marketing Committee'")
return
# This callback is used to send data to the channel:
def _setTopic(x):
irc.sendMsg(ircmsgs.topic(channel, x))

View File

@ -314,7 +314,7 @@ class MeetingCommands(object):
for messageline in message.split('\n'):
self.reply(messageline)
if line.strip():
self.do_meetingtopic(nick=nick, line=line, time_=time_, **kwargs)
self.do_meetingname(nick=nick, line=line, time_=time_, **kwargs)
def do_endmeeting(self, nick, time_, **kwargs):
"""End the meeting."""
if not self.isChair(nick): return