@openagents-org/agent-launcher 0.2.139 → 0.2.140

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@openagents-org/agent-launcher",
3
- "version": "0.2.139",
3
+ "version": "0.2.140",
4
4
  "description": "OpenAgents Launcher — install, configure, and run AI coding agents from your terminal",
5
5
  "main": "src/index.js",
6
6
  "bin": {
package/registry.json CHANGED
@@ -616,7 +616,7 @@
616
616
  "requires": ["python3"],
617
617
  "macos": "curl -fsSL https://raw.githubusercontent.com/NousResearch/hermes-agent/main/scripts/install.sh | bash -s -- --skip-setup",
618
618
  "linux": "curl -fsSL https://raw.githubusercontent.com/NousResearch/hermes-agent/main/scripts/install.sh | bash -s -- --skip-setup",
619
- "windows": "wsl.exe -e bash -lc \"curl -fsSL https://raw.githubusercontent.com/NousResearch/hermes-agent/main/scripts/install.sh | bash -s -- --skip-setup\""
619
+ "windows": "\"%SystemRoot%\\System32\\WindowsPowerShell\\v1.0\\powershell.exe\" -NoProfile -ExecutionPolicy Bypass -Command \"Invoke-RestMethod -UseBasicParsing 'https://raw.githubusercontent.com/NousResearch/hermes-agent/main/scripts/install.ps1' | Invoke-Expression\""
620
620
  },
621
621
  "launch": {
622
622
  "args": []
@@ -24,6 +24,9 @@ const { buildOpenclawSystemPrompt } = require('./workspace-prompt');
24
24
  const { whichBinary, getEnhancedEnv } = require('../paths');
25
25
 
26
26
  const IS_WINDOWS = process.platform === 'win32';
27
+ const HERMES_INSTALL_HINT = IS_WINDOWS
28
+ ? 'powershell -NoProfile -ExecutionPolicy Bypass -Command "irm https://raw.githubusercontent.com/NousResearch/hermes-agent/main/scripts/install.ps1 | iex"'
29
+ : 'curl -fsSL https://raw.githubusercontent.com/NousResearch/hermes-agent/main/scripts/install.sh | bash';
27
30
  const SESSION_ID_RE = /session_id:\s*(\S+)/;
28
31
  const MAX_HISTORY_ENTRIES = 12;
29
32
 
@@ -56,7 +59,7 @@ class HermesAdapter extends BaseAdapter {
56
59
  if (this._hermesBin) {
57
60
  this._log(`Using Hermes binary: ${this._hermesBin} (profile=${this.hermesProfile})`);
58
61
  } else {
59
- this._log('Warning: hermes CLI not found. Install: curl -fsSL https://raw.githubusercontent.com/NousResearch/hermes-agent/main/scripts/install.sh | bash');
62
+ this._log(`Warning: hermes CLI not found. Install: ${HERMES_INSTALL_HINT}`);
60
63
  }
61
64
  }
62
65
 
@@ -76,7 +79,9 @@ class HermesAdapter extends BaseAdapter {
76
79
  try {
77
80
  const env = getEnhancedEnv();
78
81
  if (IS_WINDOWS) {
79
- // Native Windows unsupported upstream — we try anyway for WSL cases
82
+ // Native Windows is supported (install.ps1). The installer adds
83
+ // venv\Scripts to the user PATH; a running daemon won't see that update,
84
+ // hence the enriched env + the explicit candidates in Tier 2.
80
85
  const r = execSync('where hermes.exe 2>nul || where hermes.cmd 2>nul || where hermes 2>nul', {
81
86
  encoding: 'utf-8', timeout: 5000, windowsHide: true, env,
82
87
  });
@@ -88,9 +93,16 @@ class HermesAdapter extends BaseAdapter {
88
93
  }
89
94
  } catch {}
90
95
 
91
- // Tier 2: Common install locations. The installer drops `hermes` in
92
- // ~/.local/bin and (on Windows) ~/.hermes/bin.
96
+ // Tier 2: Common install locations. The native Windows installer
97
+ // (install.ps1) provisions a portable venv and drops hermes.exe under
98
+ // %LOCALAPPDATA%\hermes\hermes-agent\venv\Scripts (with the uv shim in
99
+ // %LOCALAPPDATA%\hermes\bin). The Unix installer uses ~/.local/bin.
100
+ const localAppData = process.env.LOCALAPPDATA || path.join(home, 'AppData', 'Local');
93
101
  const candidates = IS_WINDOWS ? [
102
+ path.join(localAppData, 'hermes', 'hermes-agent', 'venv', 'Scripts', 'hermes.exe'),
103
+ path.join(localAppData, 'hermes', 'hermes-agent', 'venv', 'Scripts', 'hermes.cmd'),
104
+ path.join(localAppData, 'hermes', 'bin', 'hermes.exe'),
105
+ path.join(localAppData, 'hermes', 'bin', 'hermes.cmd'),
94
106
  path.join(home, '.hermes', 'bin', 'hermes.exe'),
95
107
  path.join(home, '.hermes', 'bin', 'hermes.cmd'),
96
108
  path.join(home, '.hermes', 'bin', 'hermes'),
@@ -111,10 +123,10 @@ class HermesAdapter extends BaseAdapter {
111
123
  const viaWhich = whichBinary('hermes');
112
124
  if (viaWhich) return viaWhich;
113
125
 
114
- // Tier 4 (Windows only): Hermes is not supported natively on Windows — it
115
- // installs and runs inside WSL2. If a WSL distro has hermes on its login
116
- // PATH, resolve its absolute in-WSL path; _runHermes then invokes it as
117
- // `wsl -e <path> …`.
126
+ // Tier 4 (Windows only): fall back to a WSL install if one exists. Native
127
+ // Windows (Tiers 1-3) is preferred, but a user who set hermes up inside
128
+ // WSL2 still works — resolve its absolute in-WSL path; _runHermes then
129
+ // invokes it as `wsl -e <path> …`.
118
130
  if (IS_WINDOWS) {
119
131
  const wslPath = this._resolveWslHermes();
120
132
  if (wslPath) {
@@ -283,7 +295,7 @@ class HermesAdapter extends BaseAdapter {
283
295
 
284
296
  _buildHermesCmd(prompt, resumeSessionId) {
285
297
  if (!this._hermesBin) {
286
- throw new Error('hermes CLI not found. Install with: curl -fsSL https://raw.githubusercontent.com/NousResearch/hermes-agent/main/scripts/install.sh | bash');
298
+ throw new Error(`hermes CLI not found. Install with: ${HERMES_INSTALL_HINT}`);
287
299
  }
288
300
  const args = [];
289
301
  if (this.hermesProfile && this.hermesProfile !== 'default') {
package/src/paths.js CHANGED
@@ -197,6 +197,15 @@ function _addWindowsPaths(dirs) {
197
197
  if (localAppData) _push(dirs, path.join(localAppData, 'cursor-agent'));
198
198
  _push(dirs, path.join(HOME, '.local', 'bin'));
199
199
 
200
+ // Hermes CLI native (no-WSL) installer drops hermes.exe in the portable
201
+ // venv's Scripts dir and the uv shim in %LOCALAPPDATA%\hermes\bin. Same
202
+ // registry-PATH staleness as Cursor — add explicitly so an already-running
203
+ // daemon resolves hermes via `where` without a reboot.
204
+ if (localAppData) {
205
+ _push(dirs, path.join(localAppData, 'hermes', 'hermes-agent', 'venv', 'Scripts'));
206
+ _push(dirs, path.join(localAppData, 'hermes', 'bin'));
207
+ }
208
+
200
209
  // Node.js install
201
210
  _push(dirs, path.join(programFiles, 'nodejs'));
202
211