Skip to content
Snippets Groups Projects
Commit ae1ad30c authored by Bruce Cowan's avatar Bruce Cowan
Browse files

Add datetime command

parent ab6d5534
No related branches found
No related tags found
No related merge requests found
......@@ -32,6 +32,11 @@ class Datetime(BotPlugin):
dt = datetime.now()
return dt.strftime(fmt)
@botcmd
def datetime(self, message, args):
"""Displays both the date and time in the current locale"""
return "The date and time are {}".format(self._get_date_time('%x %X'))
@botcmd
def date(self, message, args):
"""Displays the current date in the current locale"""
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment