aboutsummaryrefslogtreecommitdiff
path: root/modules/core/module-aiassist.js
diff options
context:
space:
mode:
Diffstat (limited to 'modules/core/module-aiassist.js')
-rw-r--r--modules/core/module-aiassist.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/core/module-aiassist.js b/modules/core/module-aiassist.js
index 145e248..3d04df7 100644
--- a/modules/core/module-aiassist.js
+++ b/modules/core/module-aiassist.js
@@ -2268,7 +2268,7 @@ buildSystemPrompt() {
this.terminal.security._aiToolDepth++;
try { await this.terminal.security.checkAndRun(cmd); } finally { this.terminal.security._aiToolDepth--; this.terminal.print = originalPrint; }
// Parse per-call captured output (race-free) — not shared security state
- const nfMatch = output.match(/Command not found: (\S+?)(?:\. Did you mean: (\S+)\?)?/);
+ const nfMatch = output.match(/Command not found: ([^\s.]+)(?:\. Did you mean: ([^\s.?]+)\?)?/);
if (nfMatch) {
return JSON.stringify({ error: `Command not found: ${nfMatch[1]}`, suggestion: nfMatch[2] || null });
}