Changes
1 changed files (+15/-1)
-
-
@@ -1,4 +1,5 @@from argparse import ArgumentParser from asyncio import create_task, sleep, run from random import randint, choice from re import sub
-
@@ -96,6 +97,9 @@ # Remove mentionspost = sub('(@[^ ]*)@[^ ]*', '\\1', post) if args.yes: quit() # Prompt the user res = input('Post/Retry/New input/Custom input/Quit: ') if res not in 'prnPRNcC':
-
@@ -134,6 +138,16 @@@bot.listener.on_startup async def room_joined(room_id): await bot.api.send_text_message(room_id=room_id, message=post) async def wait_quit(): await sleep(5) quit() async def run_bot(): run = create_task(bot.main()) wait = create_task(wait_quit()) bot.run() await run await wait run(run_bot())
-