# RediWM - A 300k-line Zig desktop environment with its own compositor and GUI toolkit, native apps

> Source: <https://ziggit.dev/t/rediwm-a-300k-line-zig-desktop-environment-with-its-own-compositor-and-gui-toolkit-native-apps/18637#post_1>
> Published: 2026-11-29 23:20:18+00:00

**Recommendation:** Give coding agents a scriptable IPC or command surface for inspection and testing; Codex used RediWM's 100-plus IPC commands to debug and screenshot the app without being told to.
More in the playbook "Designing agent systems": <https://wpnews.pro/playbooks/agent-architecture>

Breakdown (including comments):

| Language | Raw lines | 
|---|---|
| Zig | 300,531 | 
| C | 21,001 | 
| Python | 63,482 | 
| Total | 385,014 | 

Built-in Apps:

as well as **Image / PDF viewer**, **Text editor**, **Dock** and now a light weight terminal (libvterm)

**Interesting things learned:** when I added IPC infrastructure to test, inspect and validate (over 100 commands), codex started using it to time and debug , interact and take screenshot all by itself without even mentioning it, that was pretty cool and handy

AI used: codex, claude code, grok build and some others
