17 lines
411 B
Python
17 lines
411 B
Python
|
from telegram.ext import Updater, CommandHandler, RegexHandler
|
||
|
from . import bot
|
||
|
|
||
|
|
||
|
def main(api_token):
|
||
|
updater = Updater(api_token)
|
||
|
|
||
|
dispatcher = updater.dispatcher
|
||
|
|
||
|
dispatcher.add_handler(CommandHandler("help", bot.help))
|
||
|
dispatcher.add_handler(CommandHandler("rmath", bot.render_math))
|
||
|
dispatcher.add_handler(CommandHandler("rcmath", bot.render_math_caption))
|
||
|
|
||
|
updater.start_polling()
|
||
|
|
||
|
updater.idle()
|