fix(windows): align WebUI defaults with Hermes Agent home path

This commit is contained in:
Harlan Zhou authored and nesquena-hermes committed 2026-05-25 01:58:32 +00:00
1 parent 75e0e67af2
commit f8a7726e09
6 files changed
+69 -17

No files matched your search

+8 -4
View File
@@ -159,11 +159,15 @@ $PortFinal = if ($Port) {
}
$env:HERMES_WEBUI_HOST = $BindHostFinal
$env:HERMES_WEBUI_PORT = "$PortFinal"
if (-not $env:HERMES_WEBUI_STATE_DIR) {
$env:HERMES_WEBUI_STATE_DIR = Join-Path $env:USERPROFILE '.hermes\webui'
}
if (-not $env:HERMES_HOME) {
$env:HERMES_HOME = Join-Path $env:USERPROFILE '.hermes'
if ($env:LOCALAPPDATA) {
$env:HERMES_HOME = Join-Path $env:LOCALAPPDATA 'hermes'
} else {
$env:HERMES_HOME = Join-Path $env:USERPROFILE '.hermes'
}
}
if (-not $env:HERMES_WEBUI_STATE_DIR) {
$env:HERMES_WEBUI_STATE_DIR = Join-Path $env:HERMES_HOME 'webui'
}
# === Ensure dirs exist =================================================