From d66411b4a06ff84f6a1a58fb221a3828206ab477 Mon Sep 17 00:00:00 2001 From: "shoney.arickathil" Date: Tue, 21 Apr 2026 03:30:18 +0200 Subject: [PATCH] move blog prototype to reference --- reference/crates/.gitignore | 3 ++ reference/crates/Cargo.toml | 40 +++++++++++++++++++ .../crates}/wo-event/Cargo.toml | 0 .../crates}/wo-event/src/epoll.rs | 0 .../crates}/wo-event/src/eventfd.rs | 0 .../crates}/wo-event/src/lib.rs | 0 .../crates}/wo-event/src/signalfd.rs | 0 .../crates}/wo-event/src/timerfd.rs | 0 .../crates}/wo-htmlx/Cargo.toml | 0 .../crates}/wo-htmlx/src/ast.rs | 0 .../crates}/wo-htmlx/src/lib.rs | 0 .../crates}/wo-htmlx/src/parser.rs | 0 .../crates}/wo-htmlx/src/registry.rs | 0 .../crates}/wo-htmlx/src/render.rs | 0 .../crates}/wo-htmlx/src/value.rs | 0 .../crates}/wo-http/Cargo.toml | 0 .../crates}/wo-http/src/connection.rs | 0 .../crates}/wo-http/src/lib.rs | 0 .../crates}/wo-http/src/listener.rs | 0 .../crates}/wo-http/src/request.rs | 0 .../crates}/wo-http/src/response.rs | 0 .../crates}/wo-index/Cargo.toml | 0 .../crates}/wo-index/src/date.rs | 0 .../crates}/wo-index/src/lib.rs | 0 .../crates}/wo-index/src/tags.rs | 0 .../crates}/wo-index/src/title.rs | 0 {crates => reference/crates}/wo-md/Cargo.toml | 0 .../crates}/wo-md/src/block.rs | 0 .../crates}/wo-md/src/highlight.rs | 0 .../crates}/wo-md/src/inline.rs | 0 {crates => reference/crates}/wo-md/src/lib.rs | 0 .../crates}/wo-model/Cargo.toml | 0 .../crates}/wo-model/src/article.rs | 0 .../crates}/wo-model/src/lib.rs | 0 .../crates}/wo-model/src/loader.rs | 0 .../crates}/wo-route/Cargo.toml | 0 .../crates}/wo-route/src/lib.rs | 0 .../crates}/wo-route/src/pattern.rs | 0 .../crates}/wo-route/src/router.rs | 0 {crates => reference/crates}/wo-rt/Cargo.toml | 0 .../crates}/wo-rt/src/config.rs | 0 .../crates}/wo-rt/src/handlers.rs | 0 {crates => reference/crates}/wo-rt/src/lib.rs | 0 .../crates}/wo-rt/src/main.rs | 0 .../crates}/wo-rt/src/runtime.rs | 0 .../crates}/wo-seg/Cargo.toml | 0 .../crates}/wo-seg/src/header.rs | 0 .../crates}/wo-seg/src/lib.rs | 0 .../crates}/wo-seg/src/reader.rs | 0 .../crates}/wo-seg/src/writer.rs | 0 .../crates}/wo-serve/Cargo.toml | 0 .../crates}/wo-serve/src/lib.rs | 0 .../crates}/wo-serve/src/mime.rs | 0 .../crates}/wo-serve/src/resolve.rs | 0 .../crates}/wo-serve/src/sendfile.rs | 0 .../crates}/wo-store/Cargo.toml | 0 .../crates}/wo-store/src/lib.rs | 0 .../crates}/wo-sub/Cargo.toml | 0 .../crates}/wo-sub/src/lib.rs | 0 .../crates}/wo-watch/Cargo.toml | 0 .../crates}/wo-watch/src/lib.rs | 0 61 files changed, 43 insertions(+) create mode 100644 reference/crates/.gitignore create mode 100644 reference/crates/Cargo.toml rename {crates => reference/crates}/wo-event/Cargo.toml (100%) rename {crates => reference/crates}/wo-event/src/epoll.rs (100%) rename {crates => reference/crates}/wo-event/src/eventfd.rs (100%) rename {crates => reference/crates}/wo-event/src/lib.rs (100%) rename {crates => reference/crates}/wo-event/src/signalfd.rs (100%) rename {crates => reference/crates}/wo-event/src/timerfd.rs (100%) rename {crates => reference/crates}/wo-htmlx/Cargo.toml (100%) rename {crates => reference/crates}/wo-htmlx/src/ast.rs (100%) rename {crates => reference/crates}/wo-htmlx/src/lib.rs (100%) rename {crates => reference/crates}/wo-htmlx/src/parser.rs (100%) rename {crates => reference/crates}/wo-htmlx/src/registry.rs (100%) rename {crates => reference/crates}/wo-htmlx/src/render.rs (100%) rename {crates => reference/crates}/wo-htmlx/src/value.rs (100%) rename {crates => reference/crates}/wo-http/Cargo.toml (100%) rename {crates => reference/crates}/wo-http/src/connection.rs (100%) rename {crates => reference/crates}/wo-http/src/lib.rs (100%) rename {crates => reference/crates}/wo-http/src/listener.rs (100%) rename {crates => reference/crates}/wo-http/src/request.rs (100%) rename {crates => reference/crates}/wo-http/src/response.rs (100%) rename {crates => reference/crates}/wo-index/Cargo.toml (100%) rename {crates => reference/crates}/wo-index/src/date.rs (100%) rename {crates => reference/crates}/wo-index/src/lib.rs (100%) rename {crates => reference/crates}/wo-index/src/tags.rs (100%) rename {crates => reference/crates}/wo-index/src/title.rs (100%) rename {crates => reference/crates}/wo-md/Cargo.toml (100%) rename {crates => reference/crates}/wo-md/src/block.rs (100%) rename {crates => reference/crates}/wo-md/src/highlight.rs (100%) rename {crates => reference/crates}/wo-md/src/inline.rs (100%) rename {crates => reference/crates}/wo-md/src/lib.rs (100%) rename {crates => reference/crates}/wo-model/Cargo.toml (100%) rename {crates => reference/crates}/wo-model/src/article.rs (100%) rename {crates => reference/crates}/wo-model/src/lib.rs (100%) rename {crates => reference/crates}/wo-model/src/loader.rs (100%) rename {crates => reference/crates}/wo-route/Cargo.toml (100%) rename {crates => reference/crates}/wo-route/src/lib.rs (100%) rename {crates => reference/crates}/wo-route/src/pattern.rs (100%) rename {crates => reference/crates}/wo-route/src/router.rs (100%) rename {crates => reference/crates}/wo-rt/Cargo.toml (100%) rename {crates => reference/crates}/wo-rt/src/config.rs (100%) rename {crates => reference/crates}/wo-rt/src/handlers.rs (100%) rename {crates => reference/crates}/wo-rt/src/lib.rs (100%) rename {crates => reference/crates}/wo-rt/src/main.rs (100%) rename {crates => reference/crates}/wo-rt/src/runtime.rs (100%) rename {crates => reference/crates}/wo-seg/Cargo.toml (100%) rename {crates => reference/crates}/wo-seg/src/header.rs (100%) rename {crates => reference/crates}/wo-seg/src/lib.rs (100%) rename {crates => reference/crates}/wo-seg/src/reader.rs (100%) rename {crates => reference/crates}/wo-seg/src/writer.rs (100%) rename {crates => reference/crates}/wo-serve/Cargo.toml (100%) rename {crates => reference/crates}/wo-serve/src/lib.rs (100%) rename {crates => reference/crates}/wo-serve/src/mime.rs (100%) rename {crates => reference/crates}/wo-serve/src/resolve.rs (100%) rename {crates => reference/crates}/wo-serve/src/sendfile.rs (100%) rename {crates => reference/crates}/wo-store/Cargo.toml (100%) rename {crates => reference/crates}/wo-store/src/lib.rs (100%) rename {crates => reference/crates}/wo-sub/Cargo.toml (100%) rename {crates => reference/crates}/wo-sub/src/lib.rs (100%) rename {crates => reference/crates}/wo-watch/Cargo.toml (100%) rename {crates => reference/crates}/wo-watch/src/lib.rs (100%) diff --git a/reference/crates/.gitignore b/reference/crates/.gitignore new file mode 100644 index 0000000..fd3cd53 --- /dev/null +++ b/reference/crates/.gitignore @@ -0,0 +1,3 @@ +# Nested v1 workspace — has its own Cargo.lock and target dir. +/target +Cargo.lock diff --git a/reference/crates/Cargo.toml b/reference/crates/Cargo.toml new file mode 100644 index 0000000..72cffa8 --- /dev/null +++ b/reference/crates/Cargo.toml @@ -0,0 +1,40 @@ +# Nested workspace for the v1 writeonce blog crates. +# +# The root workspace at /Cargo.toml drives the new `.wo` runtime at crates/wo-rt. +# These thirteen crates are the previous generation of writeonce — the flat-file +# blog engine described in docs/runtime/database/07-wo-seg-migration.md. They +# are preserved here for reference: source is readable, tests still run, and +# the Phase 7 migration plan assumes a gradual trait-abstracted coexistence +# rather than deletion. +# +# To build the v1 system standalone: +# cd reference/crates && cargo build +# cd reference/crates && cargo test +# +# The v1 crates are deliberately NOT members of the root workspace. Excluding +# them avoids the `wo-rt` name collision (both v1 and v2 claim that name) and +# keeps the root build fast while the new runtime is under active development. + +[workspace] +resolver = "2" +members = [ + "wo-model", + "wo-seg", + "wo-index", + "wo-store", + "wo-watch", + "wo-event", + "wo-sub", + "wo-rt", + "wo-http", + "wo-route", + "wo-htmlx", + "wo-md", + "wo-serve", +] + +[workspace.dependencies] +serde = { version = "1", features = ["derive"] } +serde_json = "1" +bincode = "1" +libc = "0.2" diff --git a/crates/wo-event/Cargo.toml b/reference/crates/wo-event/Cargo.toml similarity index 100% rename from crates/wo-event/Cargo.toml rename to reference/crates/wo-event/Cargo.toml diff --git a/crates/wo-event/src/epoll.rs b/reference/crates/wo-event/src/epoll.rs similarity index 100% rename from crates/wo-event/src/epoll.rs rename to reference/crates/wo-event/src/epoll.rs diff --git a/crates/wo-event/src/eventfd.rs b/reference/crates/wo-event/src/eventfd.rs similarity index 100% rename from crates/wo-event/src/eventfd.rs rename to reference/crates/wo-event/src/eventfd.rs diff --git a/crates/wo-event/src/lib.rs b/reference/crates/wo-event/src/lib.rs similarity index 100% rename from crates/wo-event/src/lib.rs rename to reference/crates/wo-event/src/lib.rs diff --git a/crates/wo-event/src/signalfd.rs b/reference/crates/wo-event/src/signalfd.rs similarity index 100% rename from crates/wo-event/src/signalfd.rs rename to reference/crates/wo-event/src/signalfd.rs diff --git a/crates/wo-event/src/timerfd.rs b/reference/crates/wo-event/src/timerfd.rs similarity index 100% rename from crates/wo-event/src/timerfd.rs rename to reference/crates/wo-event/src/timerfd.rs diff --git a/crates/wo-htmlx/Cargo.toml b/reference/crates/wo-htmlx/Cargo.toml similarity index 100% rename from crates/wo-htmlx/Cargo.toml rename to reference/crates/wo-htmlx/Cargo.toml diff --git a/crates/wo-htmlx/src/ast.rs b/reference/crates/wo-htmlx/src/ast.rs similarity index 100% rename from crates/wo-htmlx/src/ast.rs rename to reference/crates/wo-htmlx/src/ast.rs diff --git a/crates/wo-htmlx/src/lib.rs b/reference/crates/wo-htmlx/src/lib.rs similarity index 100% rename from crates/wo-htmlx/src/lib.rs rename to reference/crates/wo-htmlx/src/lib.rs diff --git a/crates/wo-htmlx/src/parser.rs b/reference/crates/wo-htmlx/src/parser.rs similarity index 100% rename from crates/wo-htmlx/src/parser.rs rename to reference/crates/wo-htmlx/src/parser.rs diff --git a/crates/wo-htmlx/src/registry.rs b/reference/crates/wo-htmlx/src/registry.rs similarity index 100% rename from crates/wo-htmlx/src/registry.rs rename to reference/crates/wo-htmlx/src/registry.rs diff --git a/crates/wo-htmlx/src/render.rs b/reference/crates/wo-htmlx/src/render.rs similarity index 100% rename from crates/wo-htmlx/src/render.rs rename to reference/crates/wo-htmlx/src/render.rs diff --git a/crates/wo-htmlx/src/value.rs b/reference/crates/wo-htmlx/src/value.rs similarity index 100% rename from crates/wo-htmlx/src/value.rs rename to reference/crates/wo-htmlx/src/value.rs diff --git a/crates/wo-http/Cargo.toml b/reference/crates/wo-http/Cargo.toml similarity index 100% rename from crates/wo-http/Cargo.toml rename to reference/crates/wo-http/Cargo.toml diff --git a/crates/wo-http/src/connection.rs b/reference/crates/wo-http/src/connection.rs similarity index 100% rename from crates/wo-http/src/connection.rs rename to reference/crates/wo-http/src/connection.rs diff --git a/crates/wo-http/src/lib.rs b/reference/crates/wo-http/src/lib.rs similarity index 100% rename from crates/wo-http/src/lib.rs rename to reference/crates/wo-http/src/lib.rs diff --git a/crates/wo-http/src/listener.rs b/reference/crates/wo-http/src/listener.rs similarity index 100% rename from crates/wo-http/src/listener.rs rename to reference/crates/wo-http/src/listener.rs diff --git a/crates/wo-http/src/request.rs b/reference/crates/wo-http/src/request.rs similarity index 100% rename from crates/wo-http/src/request.rs rename to reference/crates/wo-http/src/request.rs diff --git a/crates/wo-http/src/response.rs b/reference/crates/wo-http/src/response.rs similarity index 100% rename from crates/wo-http/src/response.rs rename to reference/crates/wo-http/src/response.rs diff --git a/crates/wo-index/Cargo.toml b/reference/crates/wo-index/Cargo.toml similarity index 100% rename from crates/wo-index/Cargo.toml rename to reference/crates/wo-index/Cargo.toml diff --git a/crates/wo-index/src/date.rs b/reference/crates/wo-index/src/date.rs similarity index 100% rename from crates/wo-index/src/date.rs rename to reference/crates/wo-index/src/date.rs diff --git a/crates/wo-index/src/lib.rs b/reference/crates/wo-index/src/lib.rs similarity index 100% rename from crates/wo-index/src/lib.rs rename to reference/crates/wo-index/src/lib.rs diff --git a/crates/wo-index/src/tags.rs b/reference/crates/wo-index/src/tags.rs similarity index 100% rename from crates/wo-index/src/tags.rs rename to reference/crates/wo-index/src/tags.rs diff --git a/crates/wo-index/src/title.rs b/reference/crates/wo-index/src/title.rs similarity index 100% rename from crates/wo-index/src/title.rs rename to reference/crates/wo-index/src/title.rs diff --git a/crates/wo-md/Cargo.toml b/reference/crates/wo-md/Cargo.toml similarity index 100% rename from crates/wo-md/Cargo.toml rename to reference/crates/wo-md/Cargo.toml diff --git a/crates/wo-md/src/block.rs b/reference/crates/wo-md/src/block.rs similarity index 100% rename from crates/wo-md/src/block.rs rename to reference/crates/wo-md/src/block.rs diff --git a/crates/wo-md/src/highlight.rs b/reference/crates/wo-md/src/highlight.rs similarity index 100% rename from crates/wo-md/src/highlight.rs rename to reference/crates/wo-md/src/highlight.rs diff --git a/crates/wo-md/src/inline.rs b/reference/crates/wo-md/src/inline.rs similarity index 100% rename from crates/wo-md/src/inline.rs rename to reference/crates/wo-md/src/inline.rs diff --git a/crates/wo-md/src/lib.rs b/reference/crates/wo-md/src/lib.rs similarity index 100% rename from crates/wo-md/src/lib.rs rename to reference/crates/wo-md/src/lib.rs diff --git a/crates/wo-model/Cargo.toml b/reference/crates/wo-model/Cargo.toml similarity index 100% rename from crates/wo-model/Cargo.toml rename to reference/crates/wo-model/Cargo.toml diff --git a/crates/wo-model/src/article.rs b/reference/crates/wo-model/src/article.rs similarity index 100% rename from crates/wo-model/src/article.rs rename to reference/crates/wo-model/src/article.rs diff --git a/crates/wo-model/src/lib.rs b/reference/crates/wo-model/src/lib.rs similarity index 100% rename from crates/wo-model/src/lib.rs rename to reference/crates/wo-model/src/lib.rs diff --git a/crates/wo-model/src/loader.rs b/reference/crates/wo-model/src/loader.rs similarity index 100% rename from crates/wo-model/src/loader.rs rename to reference/crates/wo-model/src/loader.rs diff --git a/crates/wo-route/Cargo.toml b/reference/crates/wo-route/Cargo.toml similarity index 100% rename from crates/wo-route/Cargo.toml rename to reference/crates/wo-route/Cargo.toml diff --git a/crates/wo-route/src/lib.rs b/reference/crates/wo-route/src/lib.rs similarity index 100% rename from crates/wo-route/src/lib.rs rename to reference/crates/wo-route/src/lib.rs diff --git a/crates/wo-route/src/pattern.rs b/reference/crates/wo-route/src/pattern.rs similarity index 100% rename from crates/wo-route/src/pattern.rs rename to reference/crates/wo-route/src/pattern.rs diff --git a/crates/wo-route/src/router.rs b/reference/crates/wo-route/src/router.rs similarity index 100% rename from crates/wo-route/src/router.rs rename to reference/crates/wo-route/src/router.rs diff --git a/crates/wo-rt/Cargo.toml b/reference/crates/wo-rt/Cargo.toml similarity index 100% rename from crates/wo-rt/Cargo.toml rename to reference/crates/wo-rt/Cargo.toml diff --git a/crates/wo-rt/src/config.rs b/reference/crates/wo-rt/src/config.rs similarity index 100% rename from crates/wo-rt/src/config.rs rename to reference/crates/wo-rt/src/config.rs diff --git a/crates/wo-rt/src/handlers.rs b/reference/crates/wo-rt/src/handlers.rs similarity index 100% rename from crates/wo-rt/src/handlers.rs rename to reference/crates/wo-rt/src/handlers.rs diff --git a/crates/wo-rt/src/lib.rs b/reference/crates/wo-rt/src/lib.rs similarity index 100% rename from crates/wo-rt/src/lib.rs rename to reference/crates/wo-rt/src/lib.rs diff --git a/crates/wo-rt/src/main.rs b/reference/crates/wo-rt/src/main.rs similarity index 100% rename from crates/wo-rt/src/main.rs rename to reference/crates/wo-rt/src/main.rs diff --git a/crates/wo-rt/src/runtime.rs b/reference/crates/wo-rt/src/runtime.rs similarity index 100% rename from crates/wo-rt/src/runtime.rs rename to reference/crates/wo-rt/src/runtime.rs diff --git a/crates/wo-seg/Cargo.toml b/reference/crates/wo-seg/Cargo.toml similarity index 100% rename from crates/wo-seg/Cargo.toml rename to reference/crates/wo-seg/Cargo.toml diff --git a/crates/wo-seg/src/header.rs b/reference/crates/wo-seg/src/header.rs similarity index 100% rename from crates/wo-seg/src/header.rs rename to reference/crates/wo-seg/src/header.rs diff --git a/crates/wo-seg/src/lib.rs b/reference/crates/wo-seg/src/lib.rs similarity index 100% rename from crates/wo-seg/src/lib.rs rename to reference/crates/wo-seg/src/lib.rs diff --git a/crates/wo-seg/src/reader.rs b/reference/crates/wo-seg/src/reader.rs similarity index 100% rename from crates/wo-seg/src/reader.rs rename to reference/crates/wo-seg/src/reader.rs diff --git a/crates/wo-seg/src/writer.rs b/reference/crates/wo-seg/src/writer.rs similarity index 100% rename from crates/wo-seg/src/writer.rs rename to reference/crates/wo-seg/src/writer.rs diff --git a/crates/wo-serve/Cargo.toml b/reference/crates/wo-serve/Cargo.toml similarity index 100% rename from crates/wo-serve/Cargo.toml rename to reference/crates/wo-serve/Cargo.toml diff --git a/crates/wo-serve/src/lib.rs b/reference/crates/wo-serve/src/lib.rs similarity index 100% rename from crates/wo-serve/src/lib.rs rename to reference/crates/wo-serve/src/lib.rs diff --git a/crates/wo-serve/src/mime.rs b/reference/crates/wo-serve/src/mime.rs similarity index 100% rename from crates/wo-serve/src/mime.rs rename to reference/crates/wo-serve/src/mime.rs diff --git a/crates/wo-serve/src/resolve.rs b/reference/crates/wo-serve/src/resolve.rs similarity index 100% rename from crates/wo-serve/src/resolve.rs rename to reference/crates/wo-serve/src/resolve.rs diff --git a/crates/wo-serve/src/sendfile.rs b/reference/crates/wo-serve/src/sendfile.rs similarity index 100% rename from crates/wo-serve/src/sendfile.rs rename to reference/crates/wo-serve/src/sendfile.rs diff --git a/crates/wo-store/Cargo.toml b/reference/crates/wo-store/Cargo.toml similarity index 100% rename from crates/wo-store/Cargo.toml rename to reference/crates/wo-store/Cargo.toml diff --git a/crates/wo-store/src/lib.rs b/reference/crates/wo-store/src/lib.rs similarity index 100% rename from crates/wo-store/src/lib.rs rename to reference/crates/wo-store/src/lib.rs diff --git a/crates/wo-sub/Cargo.toml b/reference/crates/wo-sub/Cargo.toml similarity index 100% rename from crates/wo-sub/Cargo.toml rename to reference/crates/wo-sub/Cargo.toml diff --git a/crates/wo-sub/src/lib.rs b/reference/crates/wo-sub/src/lib.rs similarity index 100% rename from crates/wo-sub/src/lib.rs rename to reference/crates/wo-sub/src/lib.rs diff --git a/crates/wo-watch/Cargo.toml b/reference/crates/wo-watch/Cargo.toml similarity index 100% rename from crates/wo-watch/Cargo.toml rename to reference/crates/wo-watch/Cargo.toml diff --git a/crates/wo-watch/src/lib.rs b/reference/crates/wo-watch/src/lib.rs similarity index 100% rename from crates/wo-watch/src/lib.rs rename to reference/crates/wo-watch/src/lib.rs