Show HN: WASI-Env – Single-file HTML with 90 Suckless C binaries and SQLite3

3 pointsposted 6 hours ago
by badfox

2 Comments

badfox

6 hours ago

Live Demo: https://wasi-env.netlify.app/ Google Colab: https://colab.research.google.com/drive/1u4T6UZNS0xZUv5KSdSw...

  WASI-Env is a portable, single-file HTML WebAssembly execution harness 
  and POSIX terminal running locally with zero external dependencies.

  Features:
  - 90 C WASM Binaries compiled from Suckless sbase and ubase
  - 46+ wasi_snapshot_preview1 syscalls intercepted
  - Official SQLite3 C amalgamation embedded
  - Dynamic /proc VFS and POSIX termios (RAW mode)
  - In-browser C compiler (/bin/cc) generating WASM on demand
  - Persistent IndexedDB storage supporting upstream /bin/df

  Note:
  This is a messy work-in-progress prototype with many artifacts. I used 
  an earlier build of this environment as the base to isolate and create 
  a standalone 6MB single-file Doom port: https://wasi-doom.netlify.app/

  The entire single file fits in an LLM context window—feel free to 
  inspect the Colab, untangle the pieces, and hack on it.

badfox

2 hours ago

My apologies I should not have posted this. It has served as the basis for my current single-file HTML Doom port and Quake port(in the works). But its way to messy to work with on its own.

I am still working on it and I am likely going to remove the SQLite3(which was one of my original tests) portion and try to get it stable with just the suckless core C binaries(which has kind of become the target).

Thanks for looking. Sorry about the slop factory.