chore: Split the code into files

This commit is contained in:
Danil 2024-12-06 18:39:41 +03:00
parent 32289e336f
commit a442489647
2 changed files with 13 additions and 0 deletions

5
bot.py Normal file
View file

@ -0,0 +1,5 @@
from aiogram import Bot
import yaml
config = yaml.safe_load(open('config.yaml'))
bot = Bot(config['token'])

8
routers.py Normal file
View file

@ -0,0 +1,8 @@
from aiogram import Dispatcher
from events import join_chat, reactions
from commands import set_channel
def setup_routers(dp: Dispatcher):
dp.include_router(reactions.router)
dp.include_router(join_chat.router)
dp.include_router(set_channel.router)