Repository navigation
The shell folder caches every game's framework, and Settings names it (#398) - #399
1 commit merged into
Conversation
…#398) A game lived in the shell only as long as its build folder existed: dropMissing dropped it once the framework was gone, and the recovery was a full rebuild. The build now mirrors each framework into the shell folder (a hard link on one volume, a copy across), dropMissing falls back to the mirror, and the next install re-embeds from it — a deleted build folder no longer removes a game. Settings → Build tools gains the cache row the owner asked for: the name, the folder path, an Open folder button, and a caption saying what lives there and what deleting it costs. Hard-link and drop-fallback behaviours are tested (ShellMirrorTests).
|
@v0lumehi two PRs for your design review when you are up, both from the owner's rc5 test:
The owner also asked for the shell's framework recovery from the device to be considered — the issue (#398) has the analysis; the mirror approach won because pulling GBs from a device is the worse experience. |
|
One interaction to settle with this: #232 (delete a game's build folder after a successful build, with a setting) and this mirror are the same storage decision seen from two sides. If #232's deletion runs while the mirror is the only other copy, the mirror becomes the single point of failure — and if #232 deletes before the mirror is written, a crashed build loses the framework entirely. Proposals:
Please also review #400 (the shell settings page, merged) — it touches the launcher/game priority chain your GameSettingsStore defines. |
|
@LNPANDY I reviewed the mirror. The idea is right. Four changes before we build on it, and my answer to the two questions. The mirror should be an APFS clone, not a hard linkA hard link shares the file with the build folder. A rebuild that writes the framework in place changes the mirror too, so a failed rebuild breaks both copies. The mirror is the primary copyYes. The installer makes the mirrorToday only a new build mirrors, in the A failed mirror is reported
Smaller points
#232#232 stays a deletion. The build folder holds gigabytes besides the framework (the extracted game, the intermediates), and the mirror makes deleting it safe. I will change #232 so it deletes only after the installer has a mirror of that game, and refuses to delete when the mirror is missing. Then the order you describe holds and a crash between build and mirror keeps the build folder. |
Fix or feature
What and why
Implements #398. A game lived in the shell only as long as its build folder existed:
dropMissingdropped it once the framework was gone, and the recovery was a full rebuild (hours for a big game, shader cache notwithstanding).NX2Apple-shell/frameworks/after it succeeds — a hard link when the build folder sits on the same volume (zero extra space), a copy otherwise. A rebuilt game re-mirrors over the old link.dropMissingfalls back to the mirror, and the next install re-embeds from it, rewriting the library entry's path — a deleted build folder no longer removes a game from the shell.Checked
ShellMirrorTests(link → mirror exists → drop-fallback rewrites the path → without a mirror the game drops); the full suite passes; the language suites pass (the l10n tests caught my missing de/sv/fr entries for the new keys — added, German without a semicolon).