WIP rewrite of n/quotes-bot in Python with https://codeberg.org/imbev/simplematrixbotlib.
Find a file
2025-02-01 17:25:24 -06:00
.gitignore make fetch actually work 2025-01-31 20:12:41 -06:00
bot.py version+ 2025-02-01 17:25:24 -06:00
config.sample.json add !q die, admin 2025-02-01 17:11:21 -06:00
error.png add error image 2025-01-31 21:19:30 -06:00
fetch.py stub top/bottom quotes 2025-02-01 17:22:34 -06:00
README.md forgor 2025-01-31 19:07:25 -06:00

quotes-bot-python

WIP rewrite of n/quotes-bot in Python with https://codeberg.org/imbev/simplematrixbotlib.

Setup

First, make and activate a venv. There are plenty of guides online, however it usually goes like this:

python3 -m virtualenv venv && source venv/bin/activate.fish

If you use bash, you can replace source venv/bin/activate.fish with just source venv/bin/activate.

Dependencies

This bot depends on simplematrixbotlib and requests, which can be installed in your venv like this:

pip install simplematrixbotlib requests

Configuring

TODO: write docs about the config file

First, copy the sample config:

cp config.sample.json config.json

Then edit it:

$EDITOR config.json

You should be good to go! To run it, run this in the venv:

python bot.py