kq
Query a Knights of the Old Republic installation like it was plain text.
- Language
- Rust
- Source
- kolto-labs/kq
- Stars
- 1
- Last push
kq treats a KotOR or TSL game folder as structured, searchable data. It reads the archives in place, so nothing gets extracted first. Questions work the way rg works on a source tree and jq works on JSON. Start with kq which: every copy of a resource in engine resolve order, with a star on the copy the game actually loads.
Features
- which: every copy of a resource in engine resolve order (Override, modules, BIFs), with the loaded copy starred
- cat: GFF, 2DA, TLK, SSF, NCS (decompiled to NSS), MDL, walkmeshes and more as an outline, gron lines, JSON or raw bytes
- grep: regex search over decoded contents; hits are field paths, not byte offsets
- delta, patch and merge: structural diffs and three-way merges of decoded resources
- graph: an inventory of used, unused and overshadowed resources in an install
- JSON and JSONL output plus stable exit codes, so scripts can branch on results
- Works on a full install, a single module, or a folder of loose files
Install
- cargo
cargo install --git https://github.com/kolto-labs/kq --locked - macOS / Linux
curl -LsSf https://github.com/kolto-labs/kq/releases/download/v0.3.0/install.sh | KQ_REPO=kolto-labs/kq sh - Windows
powershell -ExecutionPolicy ByPass -c "Set-Item Env:KQ_REPO kolto-labs/kq; irm https://github.com/kolto-labs/kq/releases/download/v0.3.0/install.ps1 | iex"