About motd.com

About motd.com

A personal message-of-the-day + notes site, rendered entirely by Mix handlers inside cosmix-webd — server-side HTML over a per-vhost SQLite database, wrapped in the dcs.spa design-system shell.

This page doubles as a live exhibit of the Mix markdown() builtin (CommonMark + GFM via pulldown-cmark).

GL.iNet MT6000 — the flint router on the mesh


The stack

Cosmix is split across four repositories — one-way deps amp ← mix ← cos, with cosmix as the private hub:

RepoRoleCrates
ampAMP protocol family3
mixMix language + binary3
cosSubstrate libs + daemons28
cosmixPrivate orchestration hub

Everything is a message port. The lineage runs AmigaOS/ARexx → Smalltalk → Plan 9 — with an AI agent as a first-class operator. Legible, modifiable, reconstructible.

Even nested quotes work.

Text formatting

You get bold, italic, both, strikethrough, inline code, and links. Autolinks too: https://github.com/markc.

Lists

Unordered, with nesting:

  • The mesh
    • cosmix-noded — the AMP broker
    • cosmix-maild — mail + JMAP + DAV
    • cosmix-webd — this CMS
  • The shell is dcs.spa

Ordered:

  1. Write a .mix handler
  2. Reload — the change is live
  3. There is no step 3

Task list:

  • Public/private pages
  • Full GFM markdown
  • Auth unification

Code

Inline markdown("# hi") returns <h1>hi</h1>. A fenced block (Mix):

function render_body($raw)
  return markdown("" .. $raw)
end

And some Rust from the builtin itself:

let mut opts = Options::empty();
opts.insert(Options::ENABLE_TABLES);
opts.insert(Options::ENABLE_STRIKETHROUGH);

Safety

Raw HTML in the source is escaped, never active — so <script>alert(1)</script> renders as literal text, and [evil](javascript:alert(1)) has its URL neutralised. Safe by default.1

1

Link/image URL schemes javascript: / data: / vbscript: are blocked (including whitespace/control-char obfuscation); relative and normal URLs pass through.