Recover user files from orphaned state-vN.bin after a version bump (#365)

* Detect orphaned state-vN.bin and offer file recovery to a host folder

When STATE_VERSION is bumped, users previously lost their C:\ silently.
The Welcome card now detects an older state file (v4+), explains what
happened, and offers a one-click recovery: spin up a throwaway v86
(no boot), restore the legacy state to populate the hda dirty-block
overlay, walk the FAT32 tree reading overlay-if-dirty-else-base, and
copy any file the guest ever wrote out to ~/Downloads/Recovered C Drive.

Directories are created lazily so empty branches never appear; success
and failure render in the panel (no native dialogs). The geometry
constraint that keeps overlay+new-base valid is documented next to
STATE_VERSION. Also makes the dev-mode CDP port overridable via
WIN95_DEBUG_PORT so worktree instances don't fight over 9222.

* prettier
This commit is contained in:
Felix Rieseberg
2026-04-12 12:38:28 -07:00
committed by GitHub
parent fa0e4c691e
commit c847467de6
12 changed files with 669 additions and 123 deletions

View File

@@ -80,6 +80,24 @@
}
}
.welcome-warn {
background: #fff;
p {
margin: 0 0 8px;
}
.welcome-warn-buttons {
display: flex;
gap: 6px;
margin-top: 4px;
button {
height: 24px;
}
}
}
.welcome-actions {
width: 130px;
display: flex;