Expand description
Workspace abstraction: Mode S (MemoryVfsBackend) vs Mode P (GuestPrimaryBackend).
See docs/superpowers/specs/2026-03-20-devshell-guest-primary-design.md §4.
Structs§
- Guest
Primary Backend - Mode P skeleton:
GuestFsOps+ logical cwd + guest mount (see design §5). - Memory
VfsBackend - Mode S:
Vfsin memory (Rc<RefCell<Vfs>>matches REPL sharing).
Enums§
- Workspace
Backend Error - Unified error for workspace operations (until dispatch is wired).
- Workspace
Read Error - Failure reading a logical path from the active workspace (guest or VFS).
Traits§
- Workspace
Backend - Virtual workspace for devshell: Mode S (memory) or Mode P (guest-primary).
Functions§
- guest_
export_ readonly_ to_ vfs - Copy the logical subtree at
logical_srcfrom the guest into a fresh directory under/.__export_ro_<ms>/…and return that absolute logical path (printed byexport-readonly). - logical_
path_ to_ guest - Map a logical absolute path to a guest path (same layout as γ push: project root =
guest_project_dir_on_guest). - logical_
to_ guest_ abs - Map a logical path to a guest absolute path (γ guest-primary).
- read_
logical_ file_ bytes - Read file bytes for a logical path: guest-primary (γ or β) first, else in-memory
Vfs. - read_
logical_ file_ bytes_ rc - Same as
read_logical_file_byteswith sharedRchandles (script / REPL).