-.PHONY: serve test strict
-
-MODULE=cadbury
+.PHONY: serve
.venv:
python -m venv .venv
.venv/bin/pip install .
serve: .venv
- .venv/bin/python bot.py
+ .venv/bin/python app.py
clean:
rm -rf .venv
rm -f session.txt # Reset session
-test: .venv
- .venv/bin/pip install .[test]
- .venv/bin/mypy -m $(MODULE)
-
-strict: .venv
- .venv/bin/mypy --strict -m $(MODULE)
-
bot = get_bot()
@bot.listener.on_message_event
-def do_bot_stuff(room, message):
- goal_bot(room, message)
+async def do_bot_stuff(room, message):
+ await goal_bot(room, message, bot)
-bot.run()
requires-python = ">=3.12"
dependencies = [
-'goal-bot@git+https://codeberg.org/EdTheDev/matrix-goal-bot.git',
+'matrix-goal-bot@git+https://codeberg.org/EdTheDev/matrix-goal-bot.git',
'invoke',
'simplematrixbotlib',
]