DiscordWhitelist/autowl/__init__.py

20 lines
434 B
Python
Raw Normal View History

import os
2023-01-27 13:49:55 -06:00
from sys import stderr
2023-01-27 11:27:26 -06:00
import discord
# run init stuff inside this function
def init():
# make sure this prints the discord token
# set this up as a runtime environment variable, DO NOT HARDCODE THE TOKEN
2023-01-27 13:49:55 -06:00
distoken = os.environ.get("DISCORD_TOKEN")
if not distoken:
print("Unable to find discord token in environment!", file=stderr)
exit(1)
2023-01-27 13:49:55 -06:00
print(f"discord token:{distoken}")
init()