Add web modules (crypto, wiki, define, urban, tinyurl, down) + shared http/json
All checks were successful
ci / check (push) Successful in 48s

This commit is contained in:
Jean Chevronnet 2026-07-29 19:42:36 +00:00
parent 7846f91afe
commit c3139b4e4d
No known key found for this signature in database
GPG key ID: 439666D63A9477E4
14 changed files with 794 additions and 130 deletions

View file

@ -55,10 +55,13 @@ pub fn all() -> Vec<Box<dyn Module>> {
Shipped modules: **`builtins`** (`ping`, `echo`, `hello`), **`dice`**
(`roll [NdM]`), **`hash`** (`md5`/`sha1`/`sha256`/`hash <text>`, hand-rolled),
and **`weather`** (`add <location>` then `w [location]` via wttr.in; per-user
locations saved to a per-network JSON file, path from `RUSTBOT_DATA_DIR`).
Module tests live in `tests/` — construct a module and assert on the `Action`s
it returns, no network required.
**`weather`** (`add <location>` then `w [location]` via wttr.in; per-user
locations saved to a per-network JSON file, path from `RUSTBOT_DATA_DIR`), and
web lookups over the shared `http`/`json` helpers: **`crypto <sym>`** (Bitstamp),
**`wiki <term>`**, **`define <word>`**, **`urban <term>`**, **`tinyurl <url>`**,
**`down <host>`**. Module tests live in `tests/` — construct a module (or call
its pure formatter with a canned API body) and assert on the result, no network
required.
## Build & run