mirror of
https://github.com/SpiceBot/SpiceBot.git
synced 2026-11-10 21:50:59 -05:00
30 lines
634 B
Python
30 lines
634 B
Python
# coding=utf-8
|
|
|
|
from __future__ import unicode_literals, absolute_import, division, print_function
|
|
|
|
import sopel.module
|
|
|
|
import spicemanip
|
|
|
|
# import sopel_modules.SpiceBot as SpiceBot
|
|
|
|
|
|
@sopel.module.rule(r"""(?:)u/
|
|
(
|
|
(?:\\/ | [^/])+
|
|
)
|
|
""")
|
|
def bot_command_reddit_user(bot, trigger):
|
|
trigger_command = spicemanip.main(trigger.args[1], 1).lower()[:1]
|
|
bot.osd(str(trigger_command))
|
|
|
|
|
|
@sopel.module.rule(r"""(?:)r/
|
|
(
|
|
(?:\\/ | [^/])+
|
|
)
|
|
""")
|
|
def bot_command_reddit_subreddit(bot, trigger):
|
|
bot.osd(str(trigger))
|
|
bot.osd(str(trigger.args))
|