81 lines
2.6 KiB
Markdown
81 lines
2.6 KiB
Markdown
# Development and build notes
|
|
|
|
## Local development
|
|
|
|
Mudmouth requires Rust stable. On NixOS, the included shell also provides the
|
|
ALSA development metadata used by the Linux audio backend:
|
|
|
|
```bash
|
|
nix-shell
|
|
```
|
|
|
|
Run the normal validation suite before submitting a change:
|
|
|
|
```bash
|
|
cargo fmt --check
|
|
cargo clippy --all-targets -- -D warnings
|
|
cargo test
|
|
cargo build --release
|
|
```
|
|
|
|
## Refreshing the PEQ NPC gender index
|
|
|
|
The checked-in `generated/peq-npc-gender-index.json` is generated data, not a
|
|
runtime database dependency. Regenerate it from an explicit ProjectEQ dump
|
|
with the tool below; it reads either `create_tables_content.sql` directly or
|
|
the `peq-dump/create_tables_content.sql` member of the supplied zip archive.
|
|
`unzip` is available in `shell.nix` for the latter.
|
|
|
|
```bash
|
|
cargo run --bin generate_peq_npc_index -- \
|
|
--dump "$HOME/Downloads/peq-1759046415.zip" \
|
|
--output generated/peq-npc-gender-index.json
|
|
```
|
|
|
|
The tool prints its input identity, complete conflict/neuter statistics, and
|
|
output size. Run it twice and compare the output hashes before updating the
|
|
checked-in artifact. The source archive and any temporary database files must
|
|
not be committed or included in release archives.
|
|
|
|
The parser tests cover the observed log formats, including NPC dialogue,
|
|
channel-chat exclusion, zone events, normalization, persistent/random speaker
|
|
voice policies, log truncation, and first-run log discovery.
|
|
|
|
## Running locally
|
|
|
|
Start the local Kokoro FastAPI service when necessary, then pass an EverQuest
|
|
log directly:
|
|
|
|
```bash
|
|
doas systemctl start podman-kokoro-fastapi.service
|
|
cargo run --release -- --log "$HOME/Games/EverQuestLegends/Logs/eqlog_Pleb_oggok.txt"
|
|
```
|
|
|
|
Starting without a log path opens first-time setup. Mudmouth scans common Steam
|
|
and Daybreak install folders for `eqlog_*.txt` files and lets you choose a
|
|
character; if it finds none, enter the EverQuest game directory. Use `[r]` to
|
|
rescan after enabling `/log on` in EverQuest. You can also change the log path
|
|
and Kokoro endpoint from **Settings**:
|
|
|
|
```bash
|
|
cargo run --release
|
|
cargo run --release -- --kokoro-url http://127.0.0.1:8880
|
|
```
|
|
|
|
## Release builds
|
|
|
|
Build Linux and Windows binaries locally with `release.nix`, then package them
|
|
with:
|
|
|
|
```bash
|
|
nix-build release.nix -A linux -o result-linux
|
|
nix-build release.nix -A windows -o result-windows
|
|
./scripts/package-release.sh \
|
|
--linux result-linux/bin/mudmouth \
|
|
--windows result-windows/bin/mudmouth.exe
|
|
```
|
|
|
|
The packager writes platform-qualified archives and `SHA256SUMS.txt` to
|
|
`dist/`. `scripts/publish-release.sh` uploads those exact assets as a Gitea
|
|
pre-release after the worktree is committed and clean.
|