feat: persist state under plugin-state/ (runner de-privilege)
CI / publish (push) Has been skipped
CI / build (push) Failing after 1m50s

The managed runner is de-privileged on Windows now (runs as LocalService),
and %ProgramData%\punktfunk is locked read-only to it — so writing config/
cache straight under the config dir fails EPERM (proven on-glass). Move the
plugin's state to <config_dir>/plugin-state/rom-manager, which
`punktfunk-host plugins enable` grants the runner write on. On Linux the
runner owns the config dir, so the path is writable there too — one path, no
branch.

Migrate a pre-0.2.1 config/cache from the old <config_dir>/rom-manager on
first load (copy, guarded, best-effort) so an existing operator's roots +
launch templates survive the move instead of silently resetting to defaults.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
2026-07-19 23:27:33 +02:00
parent 14709d4062
commit e84cc89222
4 changed files with 113 additions and 4 deletions
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "@punktfunk/plugin-rom-manager",
"version": "0.2.0",
"version": "0.2.1",
"private": false,
"type": "module",
"description": "Punktfunk plugin: scans ROM directories, maps them to emulators, and reconciles them into the host game library as a provider — with a console-hosted web UI.",