Commit Graph
60 Commits
Author SHA1 Message Date
Nwflower e83cce28e6 feat(lifecycle): route media actions and VM logs
Add ActionDriver/LogDriver dispatch for insert, eject, NVMe upgrades and serial/QEMU logs across lifecycle, App and CLI.

Pass driver IDs through frontend media and log calls and extend second-driver action/log coverage.
2026-11-30 09:40:52 -07:00
Nwflower b6fde8fd4b feat(lifecycle): route VM details and settings by driver
Resolve details through driver.Show with a generic GetVMInfo binding, and validate/apply changes through lifecycle.Set in App and CLI.

Move guest language and OpenCore replay into ReimsMacOSDriver.Set, preserving legacy fallbacks and adding second-driver detail/settings acceptance.
2026-11-30 09:04:14 -07:00
Nwflower 8b6ca5c719 feat(lifecycle): route restart and delete by driver
Add lifecycle Delete and driver-qualified App Restart/Delete methods, CLI vm delete --driver/--keep-files, and frontend driver-aware actions.

Extend the second-driver App acceptance to restart and delete while preserving legacy macOS restart fallback and cleanup.
2026-11-30 08:56:36 -07:00
Nwflower 71fb8bb458 refactor(vmstart): split macOS preparation from host helpers
Move Prep, recovery markers, offline helper and OpenCore language handling into internal/macos/startprep while retaining memory, affinity and line-writer helpers in vmstart.

Remove the host-to-macOS vmstart architecture exception and preserve preparation and commit-memory tests on both sides.
2026-11-30 08:50:55 -07:00
Nwflower 74be2f73a9 refactor(macos): own guest tools images and tuning
Build Guest Tools images in the macOS driver after all start hooks pass, through a host callback rather than a new macOS-to-guesttools dependency.

Add driver.OptimizationAdvisor, keep generic hardware evaluation in host, and move WHPX recommendations and tests into macosdriver for both the UI and diagnostics.
2026-11-30 08:45:12 -07:00
Nwflower 7ba5e3fa9c feat(lifecycle): route VM starts through owning drivers
Change Driver.Start to StartRequest/StartResult with a compile-time macOS adapter assertion and registry-to-router coverage. Keep legacy Sidecar name alongside VMRef and grant argument privileges by driver ownership.

Move macOS preparation into ReimsMacOSDriver after hook veto, fail preparation errors before launch, and verify veto leaves OpenCore, recovery markers and ledgers unchanged.

Unify GUI, CLI and window list/start/stop through internal/lifecycle, select frontend VMs by VMRef, lazily initialize reims only in legacy CLI branches, and cover a second driver through App user entry points.
2026-11-30 08:34:20 -07:00
Nwflower 25766a9cdb refactor(guesttools): isolate registrations by VMRef
Key Guest Tools registrations, connection state, clipboard policies, text queues, and WebDAV handlers by driver-qualified VM references while preserving existing guest URLs and token authentication.

Pass VMRef through host-text callbacks and removal cleanup, with same-name coverage for authentication, policies, handlers, and independent unregister.
2026-11-30 07:59:06 -07:00
Nwflower 59aaf36eb5 refactor(app): key VM runtime state by VMRef
Qualify transitions, pending changes, reboot watchers, disk/process caches, typing queues, thumbnail locks, and VM log sources so same-named VMs do not share mutable state.

Read driver-qualified transition keys in the frontend and add --start-driver to CLI/window handoff. Legacy window start rejects other drivers explicitly until lifecycle routing lands.
2026-11-30 07:51:10 -07:00
Nwflower 9204b58987 feat(driver): disambiguate VMs with VMRef
Keep same-named VMs from different drivers, reject ambiguous bare-name resolution, and add exact ResolveRef routing with driver-qualified keys.

Declare DataRoot-relative VM roots in guest driver manifests, validate traversal and absolute paths, and scan declarations for unavailable drivers.

Add data layout v3 for driver-qualified per-VM plugin settings, preserve explicit values during migration, and pass VMRef keys from the settings UI.
2026-11-30 07:38:46 -07:00
Nwflower 5cbd7bceac feat(plugins): move macOS support into builtin.guest.macos
Declare the reims guest driver statically, merge the install guide into the optional macOS plugin, and keep compatibility settings under the new owner.

Add data layout v2 with atomic state migration, ledger backups, targeted argument ownership moves, and idempotent v1 upgrade coverage. Reduce builtin.core to the default theme.

Add a reverse import ratchet for internal/macos and document the transition. The macOS plugin remains enabled by default during migration; that default and the future privilege/trust rules remain subject to review.
2026-11-30 07:20:15 -07:00
Nwflower 6dcf33f71b feat(dataroot): guard data folder writes and migrations 2026-11-30 06:58:32 -07:00
Nwflower 2ffddf94b4 docs(plugins): plan guest migration and macOS extraction 2026-11-30 06:58:32 -07:00
Nwflower 5e39b11566 refactor(macos): isolate guest-specific code and guard host imports 2026-11-30 05:47:14 -07:00
NwflowerandClaude Opus 5.5 e259833b5f feat(plugins): rework the plugin market and first-run language packs
Market page
- Card grid that fills the width; cards show only icon, name,
  publisher (trust mark by color and icon), version and the action.
- Paints from cache via the new PeekPluginMarket binding, then revalidates;
  cards reveal 24 at a time as the feed scrolls.
- Category chips come from the index (MarketBrowseResult.kinds) instead of
  a fixed list; the alpha toggle and source badge are gone.
- Installed/Market is a segmented control; refresh now shows feedback.
- WordmarkLoader writes the Reims-Go wordmark stroke by stroke while the
  market loads (static pulse under reduced motion).

Install and enable
- reims:plugin-install events drive a progress bar on the card.
- After install, a dialog offers to enable the plugin and lists what it can
  do in plain words (PluginInfo.risks / MarketCatalogItem.risks, derived
  from tier, permissions and contributions in risks.go).
- Enabling a plugin that provides UI languages switches to the first one
  unless the current language is among them (PluginInfo.locales).

Trust
- A package installed from the project's own index, fetched over HTTPS in
  this session, inherits the index's trust level when its SHA-256 matches.
  Third-party indexes (REIMS_GO_PLUGIN_MARKET_URL) cannot vouch and show
  every entry as community.
- Trust no longer waives review: official packages get the same scan,
  high-risk approval and L3 hash check as any other; only builtin and
  bundled plugins are pre-approved.

First launch
- When the OS language is not covered by zh-CN/en-US, the folder screen
  looks up a matching pack once (SuggestLanguagePack) and offers to install
  it; Continue installs and enables it so the UI follows the OS language.
  Before setup the market keeps its index in memory only.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-30 05:17:45 -07:00
NwflowerandClaude Opus 5.5 809ce68cf3 feat(datamigrate): version the data folder and migrate it on startup
The data folder had no record of which layout wrote it, so a new release
could not tell old data from current data. <DataRoot>\.reims-go-data.json
now records data_version and the app version that last raised it. It is
kept out of reims-go.json, which is rewritten whole on every save and
would drop the field under an older build.

Each build carries every step from older layouts to its own; the GUI and
CLI run them in order before reading the folder, so users can jump
straight from any old version. A failed step leaves the version at the
last success and resumes next launch; a folder from a newer build is left
untouched.

Step v1 writes the driver ownership marker into every reims-ctl VM.
driver.RenamedDriverIDs maps old driver IDs to new ones for when a driver
moves to another plugin; markers are not rewritten, so downgrades still
resolve.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-30 05:16:38 -07:00
Nwflower de523c5323 feat(plugin,cli): add plugin pack, default keyring, and reims-go/plugins market URLs 2026-11-30 01:33:27 -07:00
Nwflower 5a5977f93e feat(plugin,cli): add static security scanner and lazy plugin market
- Add unified static security scanner and install/load gate (internal/plugin/scanner.go) blocking undeclared binaries, SVG active content, theme script escapes, and undeclared network calls while reporting L3 Sidecar privileges and SHA-256
- Add lazy plugin market client (internal/plugin/market.go) with remote index fetching (REIMS_GO_PLUGIN_MARKET_URL), memory/disk caching, embedded offline fallback, withdrawn-plugin blocking, compatibility preflight, and SHA-256 verification
- Extend CLI with plugin search/update/install <id> and enhanced .zip/--json security doctor output; update backend locale catalog and plugin architecture docs
2026-11-30 01:04:20 -07:00
Dnyo666 ceeec602be feat(i18n,plugin): implement end-to-end i18n & L10n v2 architecture and language pack protocol
- Build single-source-of-truth 7-domain locale catalog (`locales/{zh-CN,en-US}/*.json`, 1,100+ keys) and `cmd/i18ngen` generator emitting Go catalogs and eager/lazy-split TypeScript domain modules (`core`/`vm` eager; `wizard`/`settings`/`plugins` lazy)
- Add zero-dependency ICU MessageFormat subset (`{var}`, `{n, number}`, CLDR `plural`, `select`), 8-hop cycle-free regional fallback (`zh-HK/zh-MO -> zh-Hant -> zh-TW -> zh-CN`), `auto` OS display-language preference, and `en-XA` pseudo-localization across Go and TypeScript
- Introduce `CodedError` supportability with `[E_CODE]` badges, collapsible `[detail]` diagnostics, and automatic SMC OSK / SMBIOS serial / MAC / token redaction
- Add Host × Guest macOS dual-terminology annotation (`FormatGuestTerm`) across 6 official Apple guest UI locales and localize Win32 system tray, file pickers, and DPI-adaptive `installguide` overlays with CJK font fallback probing
- Upgrade L1–L4 plugin localization to dual-track v2: Track A full language packs (`files`, WOFF2 `fonts`, cross-plugin `pluginOverrides`), Track B plugin-scoped `l10n` bundles (`HasUIMessages` isolation), live `plugin/localeChanged` notifications, `< 2ms` static CLI pack loading, and `reims-go plugin locale init|check` translator toolchain with `zh-TW` and `ja-JP` reference packs
- Harden security, WCAG 2.1 AA token contrast, `< 768px` responsive drawer & form layouts, and RTL logical properties; add backend security/locale regression tests and frontend `node --test` static/runtime guard suite in CI

# Conflicts:
#	frontend/src/i18n.ts
#	internal/cli/cli.go
#	internal/i18n/i18n.go
2026-11-30 14:56:19 +08:00
Nwflower 21eef18f7b refactor(runtime,ci): remove GitCode mirror sync and download source 2026-11-29 23:10:27 -07:00
Nwflower d085734c58 docs(roadmap): track WebDAV path safety hardening and small-file I/O 2026-11-29 21:15:15 -07:00
Nwflower c91f5901a7 chore(debug,ci): add .debug workspace tooling and hygiene checks
Ignore .debug/ locally and add scripts/debug/ helpers (tmp, work, worktree, check, and tests) to enforce workspace hygiene. Run the hygiene check and self-test in CI, and document the .debug/ contract in AGENTS.md and docs/architecture.md.
2026-11-29 21:15:14 -07:00
Nwflower 354450ddcb feat(selfupdate): follow release filename on in-app update 2026-11-29 10:40:33 -07:00
Nwflower 8969c53644 Merge pull request #3 from yxc0915/feat/vm-window-install-guide
Integrate the VM-window macOS installation and recovery guide from #3
as an optional built-in plugin (builtin.install-guide):
- Register builtin.install-guide providing ui.install-guide with
  zero-residue lifecycle disposal and live toggle support
- Keep VMPage's in-page recovery guide as automatic fallback when
  the plugin is disabled
- Preserve VM-window guide UX, DPI layout, and restart resume from #3
2026-11-29 10:39:02 -07:00
Nwflower f0b69c252c feat(update,plugin,ui): add in-app self-update, plugin locale packs, and About page
- Add shared resumable + SHA256SUMS-verified downloader (internal/fetch) and Windows executable swap/relaunch flow (internal/selfupdate, internal/app/appupdate_flow.go, --wait-pid in main.go/cli).
- Add dedicated About page and sidebar update capsule with background release checks, download progress, and restart confirmation when VMs are running.
- Implement plugin-contributed UI and backend/CLI locale packs (contributes.locales, LocalizedText extra tags, validation, runtime overlay, and PopupSelect language picker).
- Move kernel-irqchip and Windows processor scheduling controls into VM Compute > Performance settings, hide Plugins settings gear for VM-only schemas, and align locked system plugin switches.
2026-11-29 10:32:11 -07:00
YXC0915 913dbdc6d9 docs: add screenshots of the VM installation guide 2026-11-30 01:07:29 +08:00
Nwflower 181c616909 feat(plugin,ui): consolidate builtin.core, enforce Guest Tools toggle, and add QQ group entry
- Merge essential builtins (driver, default theme, start prep, host workarounds) into always-on system plugin builtin.core, with state.json and arg-ledger migration plus app-scoped workaround settings honored by both GUI and CLI.
- Ensure disabling builtin.bridge.guest-tools stops the localhost bridge without being restarted by feature callers, fix guesttools.Server Start/Close race, and reflect the disabled state in VMPage and SettingsModal.
- Add QQ community group entry in About settings with Windows tencent:// protocol detection, cached invite redirect resolution, and copy-ID fallback.
- Update docs/plugin-architecture.md, Wails bindings, and i18n strings.
2026-11-29 09:54:51 -07:00
Nwflower 86d2da4a04 fix(stability,plugin): fix Windows callback leaks, add WebView2 watchdog, and harden plugin/runtime internals 2026-11-29 09:21:33 -07:00
Nwflower f30d901b7f feat(plugin): implement plugin architecture, driver router, theme engine, and CLI/GUI management 2026-11-29 08:48:00 -07:00
Nwflower b9d4544a4d docs: consolidate guides, drop one-off drafts, and sanitize local paths 2026-11-29 06:35:37 -07:00
Nwflower eb2b102bd5 perf(ui): code-split views, isolate VM stats polling, and prune finished tasks 2026-11-29 05:46:56 -07:00
Nwflower 0934d9d206 ci(runtime): strip runtime executables into detached symbols and trim unused QEMU payloads 2026-11-29 05:45:15 -07:00
Nwflower 003e4a08e7 chore(license): relicense Reims-Go from MIT to Apache-2.0 2026-11-29 05:45:15 -07:00
Nwflower 3b26f6117f refactor: move GUI App layer into internal/app 2026-11-29 02:49:49 -07:00
Nwflower 1276050569 fix(ui): show accurate window shortcuts per graphics backend (Ctrl+Alt+Win vs GTK) 2026-11-29 02:31:22 -07:00
Nwflower a7921e998b feat(runtime): add GitCode mirror source with automatic failover 2026-11-29 02:00:59 -07:00
Nwflower d21ee22c80 fix(patches): use std RandomState for Windows random_bytes in reims-ctl 2026-11-29 00:54:18 -07:00
NwflowerandClaude Opus 5.5 2f1e0bb0e4 feat(cli): fold the command line into reims-go.exe
Only reims-go.exe ships now; reims-go-cli.exe is gone. Without
arguments it opens the window, with a command it runs command-line mode
(cmd/reims-go moved to internal/cli). Missing standard handles are
attached to the parent console; handles the caller passes in (pipes,
files) are kept, so scripts and agents get output and exit codes.

`vm start` hands the VM to the window process so it gets Guest Tools
and the Win10 cold-reboot watcher, which a command that exits could not
run:
- a running window gets the request through Wails' single-instance
  protocol and stays hidden;
- otherwise the command launches the window tray-only (--background),
  detached from the caller's console and handles;
- the window writes the outcome, with the VM's last log lines on
  failure, to <DataRoot>\tmp\cli-start-*.json (it accepts no other
  path) and the command reports it.
With --data-root the VM still starts in the command itself.

The window now takes a single-instance lock: a second double-click
brings the running window forward. `wails dev` builds use their own
lock name.

Tested on Win10 19045 with macos-tahoe: start from the command line
with no window running (4 s, exit 0) and with one running (3 s, exit 0,
same process); the cold-reboot monitor was held by the window.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-28 22:52:07 -07:00
Nwflower d30c694e2f feat(guesttools): add read-only Windows drive sharing 2026-11-28 20:27:35 -07:00
NwflowerandClaude Opus 5.5 c62bf17d91 docs(roadmap): separate implemented, released and accepted; plan by user tasks
Drop version labels from milestones, add a status line per milestone, and
order follow-up work as user tasks U1-U5 with an entry bar for new features.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-28 10:52:44 -07:00
NwflowerandClaude Opus 5.5 b2237997f2 feat(input): send Chinese, emoji and host-IME text into the VM
- "Send text to VM..." dialog: arbitrary Unicode goes through Guest Tools
  (clipboard paste in the guest, agent v3 /v1/text-input long poll); without
  Guest Tools only US-keyboard ASCII is typed via QMP.
- Host IME / dictation: a low-level keyboard hook (internal/host/ime_*) catches
  VK_PACKET input aimed at a running VM window, coalesces bursts and forwards
  them in order through a per-VM queue (type_flow.go).
- reims-vgpu-window bridge: new runtime patch reims-vgpu-win32-unicode-input
  enables SDL text input and posts committed text to /v1/host-text; StartVM
  passes REIMS_GO_INPUT_URL/TOKEN to the window process. This also adds the
  patch file that patches/series.txt already listed.
- Guest Tools auth returns a field snapshot instead of copying the VM entry
  (it now holds a mutex and text queues).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-28 10:52:34 -07:00
NwflowerandClaude Opus 5.5 331d0748a4 refactor(vmstart): share VM start preparation between GUI and CLI
New internal/vmstart holds the steps both front ends need: commit-memory
precheck, offline helper disk, recovery boot picker, guest-language replay,
WHPX nested-virt compatibility, and P-core pinning after start. app.go's
StartVM and the CLI's "vm start" / "vm create --start" (cmd/reims-go/start.go)
call it, replacing memcheck.go and the copies in install/opencore flows.
"vm start" now refuses a VM that is already running instead of rewriting its
OpenCore image. Guest Tools bridging and the Win10 cold-reboot watcher still
need a long-lived process and stay GUI-only (architecture.md 3.5).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-28 10:51:23 -07:00
NwflowerandClaude Opus 5.5 d2cdb3a09a chore: drop an unused pbzx field and refresh doc pointers
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-28 10:49:52 -07:00
NwflowerandClaude Opus 5.5 ce2a0ed813 feat(runtime): rename candidate channel to alpha and build it daily from upstream
- Runtime channel "candidate" is now "alpha"; configs, the --candidate flag
  and SetRuntimeChannel("candidate") still map to alpha.
- ListRemote follows GitHub's Link pagination so stable runtimes are not
  pushed off the first page by daily alphas.
- patches/series.txt is the single patch queue for CI and pack-runtime.ps1;
  pack-runtime takes -Patches and derives allowed changed files from the
  patches (fixes a false "undeclared change" with the coroutine patch).
- build-runtime.yml runs daily: resolves upstream HEAD, skips commits already
  released, applies the queue via apply-patch-series.ps1 (skips patches
  already upstream, stops on conflicts), gates with check-runtime-alpha.ps1,
  publishes an alpha prerelease, keeps the 7 newest alphas, and files issues
  on failure or merged patches. Stable promotion stays manual.
- AGENTS.md and runtime docs updated for the alpha channel.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-28 10:42:53 -07:00
Nwflower b2f7f036d8 feat(m5): add macOS prev-lang preset, disk resize/compact, audio diagnostics, and VM thumbnails
- M5.5: add pure-Go internal/opencore reader/in-place patcher for OpenCore NVRAM prev-lang:kbd with sidecar persistence, automatic replay after update-opencore/graphics changes/CoW clones, wizard/settings/CLI (--guest-lang) support
- M5.6: add stopped VM disk resize (qemu-img resize + dynamic macOS APFS expand command) and standalone qcow2 compaction (backing-file guard, free-space check, qemu-img check, atomic swap) in GUI Settings and CLI (vm resize/compact)
- M5.9: add Win32 winmm audio output/input device probing, fix reims-ctl show audio_backend parsing, expose audio backend selector (auto/dsound/none) and latency/mic diagnostics in Settings & CLI
- UI & thumbnails: add QMP screendump VM thumbnails (internal/thumb, thumbnail_flow.go), VMPage/CreateWizard layout polish, and docs/ui-audit.md
- Update docs/roadmap.md for M5.5, M5.6, and M5.9
2026-11-28 10:17:54 -07:00
Nwflower 8b6073b6b1 fix(patches): use 64 KiB initial commit and null checks for QEMU Win32 coroutine fibers 2026-11-28 09:40:41 -07:00
Nwflower 105ca9c88e feat(v0.2.2): add Guest Tools 2.0, WebDAV share, HiDPI presets, tray, and resource bar 2026-11-28 09:40:41 -07:00
Nwflower 7b0fbd5978 release: v0.2.1 with app update checker, CI/release workflows, and upstream PR prep
Release Reims-Go / release (push) Canceled after 0s
2026-11-28 09:01:10 -07:00
Nwflower fc284e99ab feat: complete M3.4-M3.7, M4 CI/smoke pipeline, and fix Guest Tools UTF-8 clipboard
- Fix macOS Guest Tools LaunchAgent UTF-8 encoding (__CF_USER_TEXT_ENCODING=0x08000100 + LANG/LC_ALL=en_US.UTF-8) so pbpaste/pbcopy never outputs GBK mojibake on Chinese macOS, plus server-side UTF-8 validation
- M3.4: Auto-upgrade legacy AHCI to NVMe on Exit recovery mode + one-click Upgrade to NVMe banner + Windows USB/external drive (IOCTL_STORAGE_QUERY_PROPERTY BusTypeUsb) and high-RAM diagnostics
- M3.5: One-click redacted diagnostics .zip export (host report, runtime manifest, VM detail, serial/QEMU/app logs with MAC, serial, SMC OSK, and Bearer token redaction)
- M3.6: Automatic qemu-img convert for .vmdk/.raw disk imports in CreateWizard
- M3.7: Instant CoW VM derivation (CloneVMCoW + CloneDialog) preserving golden backing image untouched
- M4.2/M4.3: Add GitHub Actions CI & candidate runtime build workflows + scripts/smoke-runtime.ps1
2026-11-28 08:50:16 -07:00
Nwflower faa2b71202 feat(guest-tools): add token-authenticated clipboard & shared folder bridge and update roadmap
- Pure-Go Win32 clipboard + localhost HTTP bridge (127.0.0.1:19847) with per-VM 256-bit random Bearer token and jailed shared directory (<DataRoot>/shared/<vm>)
- Pure-Go HFS+ REIMSTOOLS virtual USB disk with stock-macOS POSIX LaunchAgent installer (no Xcode or Python needed) for two-way UTF-8 clipboard and ~/Desktop/ReimsShare sync
- VMPage Guest Tools card with live connection badge, Open shared folder, Attach/Eject tools disk, and one-click QMP install command
- Update docs/roadmap.md with v0.3/v0.4 competitor-aligned follow-up tasks
2026-11-28 08:41:09 -07:00
Nwflower 9e357ba38c fix(perf,sec): add 3-tier hybrid CPU affinity fallback and move QMP to AF_UNIX
- Detect 3-tier hybrid CPUs (P + E + LP-E, e.g. Intel Core Ultra 200 Arrow Lake) in host topology probe and select NonLPEMask (P+E, excluding slow LP-E cores) when VM vCPUs exceed P-core thread headroom
- Migrate Win10 cold-reboot secondary QMP socket from tcp:127.0.0.1:<port> to Windows AF_UNIX (reims-go-reboot.sock, with short tmp fallback) so guest code cannot reach unauthenticated QMP via SLIRP 10.0.2.2
- Automatically strip legacy tcp:127.0.0.1 QMP args on next start and update roadmap M3.2
2026-11-28 08:32:44 -07:00