Day 30

ForgeOS — A Simulated WebOS

Try it!

ForgeOS runs as a full-screen web app — open it in a new tab for the best experience.


Visit the site link

Description


Context: Days 27–29 built the Forge language from a four-command interpreter to a full Forge-to-Python compiler. For the final day I wanted to wrap the whole thing in something that felt like a product — not just a terminal, but an operating system. ForgeOS is a simulated desktop environment that runs entirely in the browser: draggable windows, a taskbar with a live clock, multiple app types, and a full Forge REPL reimplemented in JavaScript.

Challenges: Re-implementing the Forge interpreter in JavaScript meant thinking carefully about the ask command, which blocks for input in Python but needs to be handled as stateful async flow in a web terminal. The solution was a global askingFor flag — when set, the next input line goes to that variable rather than the interpreter. Draggable windows required tracking mouse offsets and cleaning up event listeners to avoid accumulating handlers. The matrix easter egg needed careful canvas timing so it could be layered over the OS without disrupting window state.

Result: A full simulated OS with three core apps (Terminal, My Sites, About), multiple hidden commands (matrix, hack nasa, sudo rm -rf /, whoami), a clock easter egg that unlocks a Vault window, and a Konami code trigger. All windows are draggable, minimizable, and maximizable. The Forge REPL supports all nine commands from Days 27–29 — plus the hidden ones.

Previous Day