added matrix support, added matrix-sdk dependency
Some checks failed
build / docker (push) Has been cancelled

This commit is contained in:
2026-02-22 17:59:57 -05:00
parent afea8a09fe
commit 598870689d
11 changed files with 2189 additions and 107 deletions

View File

@@ -2,13 +2,49 @@
![actions](https://scm.wyattjmiller.com/wymiller/CaitSith/actions/workflows/build.yml/badge.svg?branch=master)
Copyright 2025, all rights reserved
Designed and developed by Wyatt J. Miller
Copyright 2025-2026, all rights reserved
Licensed by the Eclipse Public License 2.0 (EPL-2.0). See [LICENSE.md](./LICENSE.md) for the full text.
## Description
This bot gives a user the ability to "deathroll" or roll random dice (e.g. D20). This bot can either run on Discord or Matrix.
## Building
Requirements:
- Rust (built on 1.93, 2024 edition)
- pkg-config (most Linux distributions have this already by default)
Run the following command to get a binary:
```bash
cargo build --release
```
If you are running `nix` or NixOS, you should probably run the provided `flake.nix`. The build's result will be the bot itself.
Running the binary by itself won't do anything. In fact, the bot will just quit if you don't have the needed information. You will need to have the following:
- A Discord token - `DISCORD_TOKEN`
- A guild ID - `GUILD_ID`
_OR_
- A Matrix homeserver (or admin access to one) - `MATRIX_HOMESERVER`
- A Matrix username - `MATRIX_USERNAME`
- A Matrix password - `MATRIX_PASSWORD`
Those will be environment variables. Configure them based on how you're deploying the bot—whether that's in your .bashrc, docker-compose.yml, systemd service file, etc. They need to be defined _somewhere_ in your environment.
## Hacking
Requirements:
- Rust (built on 1.86, 2021 edition)
- Rust (built on 1.93, 2024 edition)
- git
- pkg-config
- openssl-devel