* feat: extract downloaded archives in place behind a feature flag
Adds in-place extraction through hatchzip-core to the native addon. The
archive is cut back as its files come out, so extracting a download only
needs room for the game, not for the game and the archive side by side.
Only top-level archives that would be deleted after extraction are
consumed. Archives hatchzip refuses (solid RAR, files already in the way,
too little space) are left untouched and go to 7-Zip. An archive hatchzip
has started is never handed to 7-Zip and resumes from its journal.
The whole flow sits behind the IN_PLACE_ARCHIVE_EXTRACTION flag. With it
off, or with /features unreachable, archives go straight to 7-Zip and the
usual delete-or-prompt step runs afterwards.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014J6EZ4VGuJ6sWKrXDd67nW
* chore(eslint): mark the config as root
Git worktrees under .claude/worktrees sit inside the main checkout. ESLint 8
kept walking up into the outer .eslintrc.cjs, found eslint-plugin-prettier
in both node_modules folders, and crashed before linting anything, which
also broke the pre-push hook.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014J6EZ4VGuJ6sWKrXDd67nW
* chore: drop in-place extraction tests and RAR fixtures
Removes the Rust and JS tests for in-place extraction, the RAR 5 fixtures
they used, the zip dev-dependency, and the *.rar binary attribute that only
existed for those fixtures.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014J6EZ4VGuJ6sWKrXDd67nW
* fix: keep extraction retryable after an in-place extraction
An archive extracted in place is gone, but the download still pointed at
it while nested archives were extracted. If a nested extraction failed,
retrying reported the archive as missing. The extracted folder is now
saved as soon as the archive is consumed, so a retry starts from it.
Also names the progress update step count in the native addon.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014J6EZ4VGuJ6sWKrXDd67nW
* fix: keep nested archives intact when retrying after in-place extraction
The previous fix pointed the download at the extracted folder, so a retry
ran the directory extraction without the outer archive and could delete
nested archives the first attempt kept.
The download now keeps naming the archive and is marked extractedInPlace
once the archive is consumed. A retry skips the outer archive, extracts
the nested ones with the outer archive as context, and clears the mark.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014J6EZ4VGuJ6sWKrXDd67nW
* fix: resume in-place extractions only from Hydra's own record
A progress file next to an archive can arrive with a download, so it is
no longer trusted on its own. Hydra now records each archive on the
download before hatchzip may consume it, and only those archives are
resumed. A progress file Hydra did not create leaves the archive to
7-Zip.
Resuming no longer depends on the feature flag. Only a new in-place
run asks the API, once per extraction, so an offline retry finishes a
half-consumed archive instead of handing it to 7-Zip. If the addon
cannot load for a new run, 7-Zip extracts instead, and a panic in the
addon still reports whether the archive was touched.
The record also covers a run that stopped after the archive was gone:
the retry lets hatchzip finish the links and progress files, or report
the archive done, instead of failing with a missing file. Folder
downloads pick up such archives too.
hatchzip-core moves to 0.1.8, which checks that a journal only names
the archive's own volumes and links inside the output folder.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014J6EZ4VGuJ6sWKrXDd67nW
* fix: record an in-place start only for runs hatchzip can begin
The start record was saved before hatchzip rejected a journal it did
not create. If 7-Zip then failed, the record survived and the retry
resumed from the journal that came with the download.
A new run now checks for a journal before saving the record and goes
to 7-Zip if one is there. The record is also dropped whenever hatchzip
reports the archive untouched, or the addon could not run, so it only
stays for a run hatchzip actually started.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014J6EZ4VGuJ6sWKrXDd67nW
* feat: delete archive files after extraction by default
The "delete archive files after extraction" checkbox now starts
checked for anyone who has not set the preference, in the download
modal and settings of both the desktop UI and Big Picture. The main
process falls back to the same default. A preference someone already
saved keeps its value.
In-place extraction only runs for archives that are deleted afterwards,
so this lets new downloads use it without a settings change.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014J6EZ4VGuJ6sWKrXDd67nW
---------
Co-authored-by: Chubby Granny Chaser <hydralauncher@proton.me>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>