INNER CODE UNIT · Python
send_welcome
TechXueXi/TechXueXi · SourcePackages/telegramListener.py:24
def send_welcome(message):
bot.reply_to(message, "一起来学xi吧!\n输入 /help 获取帮助。")
@bot.message_handler(commands=['help'], func=authorize)
def get_help(message):
bot.reply_to(message,
"/help 获取帮助\n" +
"/learn 开始学习, /learn 张三 指定账号学习\n" +
"/list 获取账号列表\n" +
"/add 添加新账号\n" +
"/update 更新代码\n")
@bot.message_handler(commands=['learn'], func=authorize)
@exception_catcher(reserve_fun=bot.reply_to, fun_args=("学习崩溃啦",), args_push=True)
def learn(message):
params = message.text.split(" ")