Added Docker Stuff + Rearranged Files and Folders

This commit is contained in:
Discord Bot
2023-03-08 15:56:23 +00:00
parent 2704e92ba9
commit d5e009714e
9 changed files with 23 additions and 1 deletions

34
code/wingl.py Normal file
View File

@@ -0,0 +1,34 @@
import hikari
import lightbulb
import logging
import configparser
from module.rainer_board import rainerSpruche
config = configparser.ConfigParser()
config.read('config.ini')
spruchDatei = config.get('GENERAL','spruchDatei')
botToken = config.get('BOT','token')
bot = lightbulb.BotApp(
token=botToken
)
@bot.listen(hikari.StartedEvent)
async def onStarted(event):
print('Der Bot wurde gestartet!')
@bot.listen(hikari.StoppedEvent)
async def onStopped(event):
print('Der Bot wurde gestoppt!')
@bot.command
@lightbulb.command('haider', 'Meddld nen krassen Spruch raus etzadla!')
@lightbulb.implements(lightbulb.SlashCommand)
async def haider(ctx):
spruch = rainerSpruche(spruchDatei)
await ctx.respond(spruch.randomSpruch())
bot.run()