Migration: existing posts/ into the project world #103

Closed
opened 2026-10-12 17:25:23 +02:00 by AlexKucera · 1 comment
Owner

Part of #97.

Question

How does existing content move into the project world? Today the Home is posts/<id>/ flat; the ruling says projects/<name>/<piece-id>/. Decide: does every existing post land in a default project (and what is it named — Journal? Misc? Unfiled?) or does the scan read both layouts during a transition? Folders moved at first launch, lazily on open, or a one-shot migration with the old layout kept readable? What happens to the FSEvents watcher roots (posts/ → projects/ + archive/) mid-transition? Rule the migration story and the default-project semantics.

[Generated by AI]

Part of #97. ## Question How does existing content move into the project world? Today the Home is `posts/<id>/` flat; the ruling says `projects/<name>/<piece-id>/`. Decide: does every existing post land in a default project (and what is it named — Journal? Misc? Unfiled?) or does the scan read both layouts during a transition? Folders moved at first launch, lazily on open, or a one-shot migration with the old layout kept readable? What happens to the FSEvents watcher roots (`posts/` → `projects/` + `archive/`) mid-transition? Rule the migration story and the default-project semantics. [Generated by AI]
AlexKucera added the wayfinder:grilling label 2026-10-12 17:25:23 +02:00
AlexKucera self-assigned this 2026-10-12 17:30:31 +02:00
Author
Owner

Resolution

No migration machinery. The old layout holds 4 dev-only test posts; the move to projects/ is manual, by hand, when the build lands. The app never reads posts/ again — Post.scan and the FSEvents watcher root switch to projects/ (+ archive/, #99); bind(home:) creates projects/ where it today creates posts/.

Default project: posts. An ordinary project — renamable, archivable, lazily materialized — and the standing default target: New Post keeps today's zero-friction flow (no project ask). Writer-visible behavior unchanged; only the path deepens to projects/posts/<id>/.

Slug namespace stays global (the #60 machinery carries over): availableSlug enumerates projects/*/; a Post ID remains the durable identity, so all id-derived addressing (sessions, sidecars) is untouched. Cross-project intro/ collisions are a non-problem next to threading (project, id) through every path.

Finder is the v1 move/rename surface for projects and pieces — folder-shaped truth, #99's Finder-visible posture; the debounced full rescan (#61) reconciles any Finder-side move or rename. No in-app move/rename UI in this map's build.

Leftovers: nothing to handle — no code touches the old layout; the scan already skips non-post dirs wherever they sit.

[Generated by AI]

## Resolution **No migration machinery.** The old layout holds 4 dev-only test posts; the move to `projects/` is manual, by hand, when the build lands. The app never reads `posts/` again — `Post.scan` and the FSEvents watcher root switch to `projects/` (+ `archive/`, #99); `bind(home:)` creates `projects/` where it today creates `posts/`. **Default project: `posts`.** An ordinary project — renamable, archivable, lazily materialized — and the standing default target: New Post keeps today's zero-friction flow (no project ask). Writer-visible behavior unchanged; only the path deepens to `projects/posts/<id>/`. **Slug namespace stays global** (the #60 machinery carries over): `availableSlug` enumerates `projects/*/`; a Post ID remains the durable identity, so all id-derived addressing (sessions, sidecars) is untouched. Cross-project `intro/` collisions are a non-problem next to threading `(project, id)` through every path. **Finder is the v1 move/rename surface** for projects and pieces — folder-shaped truth, #99's Finder-visible posture; the debounced full rescan (#61) reconciles any Finder-side move or rename. No in-app move/rename UI in this map's build. **Leftovers:** nothing to handle — no code touches the old layout; the scan already skips non-post dirs wherever they sit. [Generated by AI]
Sign in to join this conversation.