mirror of
https://github.com/RGBCube/VReplBot
synced 2025-07-26 07:57:47 +00:00
Add repl.py
This commit is contained in:
parent
ec2bafb249
commit
9eb87f0c8d
8 changed files with 50 additions and 3 deletions
29
v_repl_bot/__main__.py
Normal file
29
v_repl_bot/__main__.py
Normal file
|
@ -0,0 +1,29 @@
|
|||
from __future__ import annotations
|
||||
|
||||
import json
|
||||
from os import environ as env
|
||||
from pathlib import Path
|
||||
|
||||
import uvloop
|
||||
|
||||
from . import ReplBot
|
||||
|
||||
|
||||
def main() -> None:
|
||||
uvloop.install()
|
||||
|
||||
config = json.loads(
|
||||
(
|
||||
Path(__file__).parent / "config.json"
|
||||
).read_text()
|
||||
)
|
||||
|
||||
env[f"JISHAKU_HIDE"] = "True"
|
||||
env[f"JISHAKU_NO_UNDERSCORE"] = "True"
|
||||
|
||||
bot = ReplBot(
|
||||
token = config["BOT_TOKEN"],
|
||||
webhook_url = config["WEBHOOK_URL"]
|
||||
)
|
||||
|
||||
bot.run()
|
Loading…
Add table
Add a link
Reference in a new issue