Skip to content

refactor(fuse): split the daemon into modules by role - #9

Merged
MotherSphere merged 1 commit into
mainfrom
refactor/fuse-modules
Aug 4, 2026
Merged

refactor(fuse): split the daemon into modules by role#9
MotherSphere merged 1 commit into
mainfrom
refactor/fuse-modules

Conversation

@MotherSphere

Copy link
Copy Markdown
Member

Pure moves out of a 2437-line lib.rs, routed by item name so anything unrouted is a compile error rather than a silent loss. Layout and proofs in the commit message; the 23-case union suite ran green against a real FUSE mount. One deliberate rename: the dispatcher module is ops because a module named fs shadows std::fs.

Hold the merge until one real Skyrim launch has run over this build - the union test covers the semantics, but the only true test of the daemon is a game on top of it.

lib.rs was 2437 lines - the whole daemon in one file, and the largest single
file left in the workspace now that the GUI is split. Pure moves, routed by
item name so anything unrouted stays behind as a compile error rather than
vanishing:

  lib.rs     493   Eidos itself: the struct, mount/spawn, resolution helpers
  ops.rs     979   impl Filesystem - one handler per FUSE opcode
                   (ops, because a module named fs would shadow std::fs)
  stats.rs   257   counters and timings, printed at unmount
  inodes.rs  237   the path<->inode table, attr cache, per-handle state
  config.rs  179   every env knob and mount option in one place
  sys.rs     175   thin syscall wrappers: positional I/O, xattrs, statvfs
  tests.rs   193   the unit tests, as a file-backed cfg(test) module

Moved items and the fields read across module lines gained pub(crate); trait
impls were left untouched since their items cannot carry visibility.

Verified the way the GUI split was: top-level item inventory identical before
and after (the 13 apparent additions are the test fns surfacing from the inline
module - 74 methods before, 61 + 13 after), the 13 unit tests green, and the
23-case union integration suite green against a real FUSE mount.
@MotherSphere
MotherSphere merged commit 484b894 into main Aug 4, 2026
5 of 6 checks passed
@MotherSphere
MotherSphere deleted the refactor/fuse-modules branch August 4, 2026 15:16
@github-actions github-actions Bot mentioned this pull request Aug 4, 2026
MotherSphere added a commit that referenced this pull request Aug 12, 2026
Brings in the six PRs merged since this branch was cut (#8 parity, #9-#12
crate splits, #13 the overwrite index) plus the 1.3.0 release.

Two conflicts, both in the Settings screen, which main rewrote into Colony's
collapsible sections while this branch was replacing the API-key field with
OAuth sign-in. Resolved by keeping main's structure and putting the sign-in
UI inside it: the Account section now holds the sign-in / sign-out pair and
the session status instead of a masked key field, and the app state keeps
`settings_expanded` while dropping `settings_api_key`, which no longer has
anything to hold.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant