mirror of
https://github.com/rommapp/romm.git
synced 2026-11-28 17:48:31 +01:00
Both exporters rebuilt their file from the database on every run, so a scan with `scan.gamelist.export: true` threw away everything the frontend or the user had written into it: favorites, play counts, per-game emulator and core overrides, hashes, `<folder>` entries, ES-DE's `<alternativeEmulator>` block, and Pegasus launch commands. The exporters now read the existing file first and merge into it. For a ROM RomM knows, the tags and keys RomM emits replace the old ones and everything else is carried over. Entries with no matching ROM, folders, scraper provider blocks and later Pegasus collections are written back untouched. A file that cannot be parsed or decoded is left alone and the export for that platform fails instead of replacing it. Fixes #4158 Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01XjH6MYLVFVoY92JdBFgKXw