PluralKit/src/bot_main.py

12 lines
330 B
Python
Raw Normal View History

2018-07-12 00:47:44 +02:00
import asyncio
2019-03-07 16:29:46 +01:00
import sys
2018-12-10 19:32:31 +01:00
try:
# uvloop doesn't work on Windows, therefore an optional dependency
import uvloop
asyncio.set_event_loop_policy(uvloop.EventLoopPolicy())
except ImportError:
pass
2018-07-12 00:47:44 +02:00
2019-03-08 17:22:05 +01:00
from pluralkit import bot
bot.run(bot.Config.from_file_and_env(sys.argv[1] if len(sys.argv) > 1 else "pluralkit.conf"))