lacy 1.8.24 → 1.8.26

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.
Files changed (3) hide show
  1. package/README.md +1 -1
  2. package/index.mjs +32 -3
  3. package/package.json +2 -2
package/README.md CHANGED
@@ -49,7 +49,7 @@ $ git status runs in shell
49
49
  ? fix the build error AI answers
50
50
  ```
51
51
 
52
- Works with lash, claude, opencode, gemini, codex, hermes, copilot, goose, amp, aider, or a custom command.
52
+ Works with lash, claude, opencode, gemini, codex, hermes, copilot, goose, aider, or a custom command.
53
53
 
54
54
  ## Other install methods
55
55
 
package/index.mjs CHANGED
@@ -39,7 +39,7 @@ const GIT_ENV = { ...process.env, GIT_TERMINAL_PROMPT: "0" };
39
39
  const STATE_FILES = ["config.yaml", "current_mode", "logs", ".last_session", ".server.pid"];
40
40
 
41
41
  // Keep in sync with LACY_TOOL_LIST in lib/core/constants.sh (tests check).
42
- const TOOL_LIST = ["lash", "claude", "opencode", "gemini", "codex", "hermes", "copilot", "goose", "amp", "aider"];
42
+ const TOOL_LIST = ["lash", "claude", "opencode", "gemini", "codex", "hermes", "copilot", "goose", "aider"];
43
43
 
44
44
  const TOOL_HINTS = {
45
45
  lash: "AI coding agent, lash.lacy.sh (recommended)",
@@ -50,10 +50,22 @@ const TOOL_HINTS = {
50
50
  hermes: "Hermes Agent by Nous Research",
51
51
  copilot: "GitHub Copilot CLI",
52
52
  goose: "Goose agent by Block",
53
- amp: "Sourcegraph Amp CLI",
54
53
  aider: "Aider pair programming",
55
54
  };
56
55
 
56
+ // Keep in sync with lacy_tool_install_cmd in lib/core/mcp.sh (tests check).
57
+ const INSTALL_CMDS = {
58
+ lash: "npm install -g lashcode",
59
+ claude: "npm install -g @anthropic-ai/claude-code",
60
+ opencode: "npm install -g opencode-ai",
61
+ gemini: "npm install -g @google/gemini-cli",
62
+ codex: "npm install -g @openai/codex",
63
+ hermes: "curl -fsSL https://raw.githubusercontent.com/NousResearch/hermes-agent/main/scripts/install.sh | bash",
64
+ copilot: "npm install -g @github/copilot",
65
+ goose: "brew install block-goose-cli",
66
+ aider: "pipx install aider-chat",
67
+ };
68
+
57
69
  const MODES = [
58
70
  { value: "auto", label: "Auto", hint: "smart detection (recommended)" },
59
71
  { value: "shell", label: "Shell", hint: "all commands execute directly" },
@@ -282,7 +294,7 @@ function defaultConfig(active = "", customCommand = "") {
282
294
  : ' # custom_command: "your-command --flags"';
283
295
  return `# Lacy Shell configuration
284
296
  agent_tools:
285
- # lash, claude, opencode, gemini, codex, hermes, copilot, goose, amp, aider, custom
297
+ # lash, claude, opencode, gemini, codex, hermes, copilot, goose, aider, custom
286
298
  # Leave empty to auto-detect.
287
299
  ${activeLine}
288
300
  ${customLine}
@@ -727,6 +739,23 @@ async function dashboard() {
727
739
  writeConfigValue("active", "");
728
740
  p.log.success(`Tool set to: ${pc.cyan("auto-detect")}`);
729
741
  } else {
742
+ // Every query would fail with a missing tool: offer to install it
743
+ if (!commandExists(selectedTool)) {
744
+ const cmd = INSTALL_CMDS[selectedTool];
745
+ const install = await p.confirm({
746
+ message: `${selectedTool} is not installed. Install it now? (${cmd})`,
747
+ });
748
+ if (p.isCancel(install) || !install) {
749
+ p.log.error(`${selectedTool} is not installed, so the tool was not changed.`);
750
+ continue;
751
+ }
752
+ const result = spawnSync("sh", ["-c", cmd], { stdio: "inherit" });
753
+ if (result.status !== 0 || !commandExists(selectedTool)) {
754
+ p.log.error(`Installing ${selectedTool} failed, so the tool was not changed. To try it yourself: ${cmd}`);
755
+ continue;
756
+ }
757
+ p.log.success(`${selectedTool} installed. If it asks you to sign in, run: ${selectedTool}`);
758
+ }
730
759
  writeConfigValue("active", selectedTool);
731
760
  p.log.success(`Tool set to: ${pc.cyan(selectedTool)}`);
732
761
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "lacy",
3
- "version": "1.8.24",
3
+ "version": "1.8.26",
4
4
  "description": "Installer for lacy. Talk to your shell: commands run, questions go to your AI coding tool.",
5
5
  "type": "module",
6
6
  "bin": {
@@ -33,7 +33,7 @@
33
33
  },
34
34
  "homepage": "https://lacy.sh",
35
35
  "dependencies": {
36
- "@clack/prompts": "^0.7.0",
36
+ "@clack/prompts": "^1.8.1",
37
37
  "picocolors": "^1.0.0"
38
38
  },
39
39
  "engines": {