From f3ebf3a99dfd53bff6a3e6fa5e3498116063f03c Mon Sep 17 00:00:00 2001 From: Minsu Lee <1964421+amondnet@users.noreply.github.com> Date: Sun, 22 Nov 2026 12:10:58 +0900 Subject: [PATCH 1/4] feat(plugins): add auto_install userConfig to LSP plugins Each plugin declares userConfig.auto_install (boolean, default true) and gates its npm SessionStart install hook on it. --- plugins/astro-lsp/.claude-plugin/plugin.json | 10 +++++++++- plugins/bash-lsp/.claude-plugin/plugin.json | 10 +++++++++- plugins/clangd-lsp/.claude-plugin/plugin.json | 10 +++++++++- .../code-intelligence-lsp/.claude-plugin/plugin.json | 12 ++++++++++-- plugins/csharp-lsp/.claude-plugin/plugin.json | 10 +++++++++- plugins/dart-lsp/.claude-plugin/plugin.json | 10 +++++++++- plugins/dockerfile-lsp/.claude-plugin/plugin.json | 10 +++++++++- plugins/elixir-lsp/.claude-plugin/plugin.json | 10 +++++++++- plugins/eslint-lsp/.claude-plugin/plugin.json | 10 +++++++++- plugins/fsharp-lsp/.claude-plugin/plugin.json | 10 +++++++++- plugins/graphql-lsp/.claude-plugin/plugin.json | 10 +++++++++- plugins/jdtls-lsp/.claude-plugin/plugin.json | 10 +++++++++- plugins/kotlin-lsp/.claude-plugin/plugin.json | 10 +++++++++- plugins/lua-lsp/.claude-plugin/plugin.json | 10 +++++++++- plugins/php-lsp/.claude-plugin/plugin.json | 10 +++++++++- plugins/prisma-lsp/.claude-plugin/plugin.json | 10 +++++++++- plugins/pyright-lsp/.claude-plugin/plugin.json | 10 +++++++++- plugins/rubocop-lsp/.claude-plugin/plugin.json | 10 +++++++++- plugins/svelte-lsp/.claude-plugin/plugin.json | 10 +++++++++- plugins/terraform-lsp/.claude-plugin/plugin.json | 10 +++++++++- plugins/texlab-lsp/.claude-plugin/plugin.json | 10 +++++++++- plugins/typescript-lsp/.claude-plugin/plugin.json | 10 +++++++++- plugins/vue-lsp/.claude-plugin/plugin.json | 10 +++++++++- plugins/yaml-lsp/.claude-plugin/plugin.json | 10 +++++++++- plugins/zls-lsp/.claude-plugin/plugin.json | 10 +++++++++- 25 files changed, 226 insertions(+), 26 deletions(-) diff --git a/plugins/astro-lsp/.claude-plugin/plugin.json b/plugins/astro-lsp/.claude-plugin/plugin.json index 12cb83e..ae544ff 100644 --- a/plugins/astro-lsp/.claude-plugin/plugin.json +++ b/plugins/astro-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\"" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } @@ -33,5 +33,13 @@ } } } + }, + "userConfig": { + "auto_install": { + "type": "boolean", + "title": "Auto-install language server", + "description": "Install and update the language server in the plugin data directory at session start. Turn off to skip it; the server then runs whatever is already installed there.", + "default": true + } } } diff --git a/plugins/bash-lsp/.claude-plugin/plugin.json b/plugins/bash-lsp/.claude-plugin/plugin.json index 0a25878..5d26ac9 100644 --- a/plugins/bash-lsp/.claude-plugin/plugin.json +++ b/plugins/bash-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "[ -x \"${CLAUDE_PLUGIN_DATA}/node_modules/.bin/bash-language-server\" ] && diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\"" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) [ -x \"${CLAUDE_PLUGIN_DATA}/node_modules/.bin/bash-language-server\" ] && diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } @@ -31,5 +31,13 @@ ".ksh": "shellscript" } } + }, + "userConfig": { + "auto_install": { + "type": "boolean", + "title": "Auto-install language server", + "description": "Install and update the language server in the plugin data directory at session start. Turn off to skip it; the server then runs whatever is already installed there.", + "default": true + } } } diff --git a/plugins/clangd-lsp/.claude-plugin/plugin.json b/plugins/clangd-lsp/.claude-plugin/plugin.json index 49da599..c03a26a 100644 --- a/plugins/clangd-lsp/.claude-plugin/plugin.json +++ b/plugins/clangd-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "[ -x \"${CLAUDE_PLUGIN_DATA}/node_modules/.bin/code\" ] && diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\"" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) [ -x \"${CLAUDE_PLUGIN_DATA}/node_modules/.bin/code\" ] && diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } @@ -38,5 +38,13 @@ ".h++": "cpp" } } + }, + "userConfig": { + "auto_install": { + "type": "boolean", + "title": "Auto-install language server", + "description": "Install and update the language server in the plugin data directory at session start. Turn off to skip it; the server then runs whatever is already installed there.", + "default": true + } } } diff --git a/plugins/code-intelligence-lsp/.claude-plugin/plugin.json b/plugins/code-intelligence-lsp/.claude-plugin/plugin.json index 045acc2..31b61ad 100644 --- a/plugins/code-intelligence-lsp/.claude-plugin/plugin.json +++ b/plugins/code-intelligence-lsp/.claude-plugin/plugin.json @@ -12,11 +12,19 @@ "hooks": [ { "type": "command", - "command": "diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\"" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } ] }, - "lspServers": "./.lsp.json" + "lspServers": "./.lsp.json", + "userConfig": { + "auto_install": { + "type": "boolean", + "title": "Auto-install language server", + "description": "Install and update the language server in the plugin data directory at session start. Turn off to skip it; the server then runs whatever is already installed there.", + "default": true + } + } } diff --git a/plugins/csharp-lsp/.claude-plugin/plugin.json b/plugins/csharp-lsp/.claude-plugin/plugin.json index c315b08..c5701d1 100644 --- a/plugins/csharp-lsp/.claude-plugin/plugin.json +++ b/plugins/csharp-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\"" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } @@ -29,5 +29,13 @@ ".cs": "csharp" } } + }, + "userConfig": { + "auto_install": { + "type": "boolean", + "title": "Auto-install language server", + "description": "Install and update the language server in the plugin data directory at session start. Turn off to skip it; the server then runs whatever is already installed there.", + "default": true + } } } diff --git a/plugins/dart-lsp/.claude-plugin/plugin.json b/plugins/dart-lsp/.claude-plugin/plugin.json index 3c6d9d2..28eb82e 100644 --- a/plugins/dart-lsp/.claude-plugin/plugin.json +++ b/plugins/dart-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "test -x \"${CLAUDE_PLUGIN_DATA}/node_modules/.bin/code\" && diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\"" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) test -x \"${CLAUDE_PLUGIN_DATA}/node_modules/.bin/code\" && diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } @@ -29,5 +29,13 @@ ".dart": "dart" } } + }, + "userConfig": { + "auto_install": { + "type": "boolean", + "title": "Auto-install language server", + "description": "Install and update the language server in the plugin data directory at session start. Turn off to skip it; the server then runs whatever is already installed there.", + "default": true + } } } diff --git a/plugins/dockerfile-lsp/.claude-plugin/plugin.json b/plugins/dockerfile-lsp/.claude-plugin/plugin.json index 11c5830..cd10a9b 100644 --- a/plugins/dockerfile-lsp/.claude-plugin/plugin.json +++ b/plugins/dockerfile-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\"" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } @@ -28,5 +28,13 @@ ".dockerfile": "dockerfile" } } + }, + "userConfig": { + "auto_install": { + "type": "boolean", + "title": "Auto-install language server", + "description": "Install and update the language server in the plugin data directory at session start. Turn off to skip it; the server then runs whatever is already installed there.", + "default": true + } } } diff --git a/plugins/elixir-lsp/.claude-plugin/plugin.json b/plugins/elixir-lsp/.claude-plugin/plugin.json index d1f20e0..de3077f 100644 --- a/plugins/elixir-lsp/.claude-plugin/plugin.json +++ b/plugins/elixir-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || (rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" && false)" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || (rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" && false) ;; esac" } ] } @@ -30,5 +30,13 @@ ".exs": "elixir" } } + }, + "userConfig": { + "auto_install": { + "type": "boolean", + "title": "Auto-install language server", + "description": "Install and update the language server in the plugin data directory at session start. Turn off to skip it; the server then runs whatever is already installed there.", + "default": true + } } } diff --git a/plugins/eslint-lsp/.claude-plugin/plugin.json b/plugins/eslint-lsp/.claude-plugin/plugin.json index f29e6a5..05c6af2 100644 --- a/plugins/eslint-lsp/.claude-plugin/plugin.json +++ b/plugins/eslint-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\"" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } @@ -37,5 +37,13 @@ ".vue": "vue" } } + }, + "userConfig": { + "auto_install": { + "type": "boolean", + "title": "Auto-install language server", + "description": "Install and update the language server in the plugin data directory at session start. Turn off to skip it; the server then runs whatever is already installed there.", + "default": true + } } } diff --git a/plugins/fsharp-lsp/.claude-plugin/plugin.json b/plugins/fsharp-lsp/.claude-plugin/plugin.json index 4885859..8d0e394 100644 --- a/plugins/fsharp-lsp/.claude-plugin/plugin.json +++ b/plugins/fsharp-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "([ -x \"${CLAUDE_PLUGIN_DATA}/node_modules/.bin/code\" ] && diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1) || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\"" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) ([ -x \"${CLAUDE_PLUGIN_DATA}/node_modules/.bin/code\" ] && diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1) || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } @@ -32,5 +32,13 @@ ".fsscript": "fsharp" } } + }, + "userConfig": { + "auto_install": { + "type": "boolean", + "title": "Auto-install language server", + "description": "Install and update the language server in the plugin data directory at session start. Turn off to skip it; the server then runs whatever is already installed there.", + "default": true + } } } diff --git a/plugins/graphql-lsp/.claude-plugin/plugin.json b/plugins/graphql-lsp/.claude-plugin/plugin.json index 103158b..9e18b19 100644 --- a/plugins/graphql-lsp/.claude-plugin/plugin.json +++ b/plugins/graphql-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\"" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } @@ -37,5 +37,13 @@ ".vue": "vue" } } + }, + "userConfig": { + "auto_install": { + "type": "boolean", + "title": "Auto-install language server", + "description": "Install and update the language server in the plugin data directory at session start. Turn off to skip it; the server then runs whatever is already installed there.", + "default": true + } } } diff --git a/plugins/jdtls-lsp/.claude-plugin/plugin.json b/plugins/jdtls-lsp/.claude-plugin/plugin.json index 632905e..1672534 100644 --- a/plugins/jdtls-lsp/.claude-plugin/plugin.json +++ b/plugins/jdtls-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || (rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" && exit 1)" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || (rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" && exit 1) ;; esac" } ] } @@ -29,5 +29,13 @@ ".java": "java" } } + }, + "userConfig": { + "auto_install": { + "type": "boolean", + "title": "Auto-install language server", + "description": "Install and update the language server in the plugin data directory at session start. Turn off to skip it; the server then runs whatever is already installed there.", + "default": true + } } } diff --git a/plugins/kotlin-lsp/.claude-plugin/plugin.json b/plugins/kotlin-lsp/.claude-plugin/plugin.json index 1b9d31e..aebe15d 100644 --- a/plugins/kotlin-lsp/.claude-plugin/plugin.json +++ b/plugins/kotlin-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\"" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } @@ -30,5 +30,13 @@ ".kts": "kotlin" } } + }, + "userConfig": { + "auto_install": { + "type": "boolean", + "title": "Auto-install language server", + "description": "Install and update the language server in the plugin data directory at session start. Turn off to skip it; the server then runs whatever is already installed there.", + "default": true + } } } diff --git a/plugins/lua-lsp/.claude-plugin/plugin.json b/plugins/lua-lsp/.claude-plugin/plugin.json index 6be8c9c..e75f05e 100644 --- a/plugins/lua-lsp/.claude-plugin/plugin.json +++ b/plugins/lua-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\"" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } @@ -29,5 +29,13 @@ ".lua": "lua" } } + }, + "userConfig": { + "auto_install": { + "type": "boolean", + "title": "Auto-install language server", + "description": "Install and update the language server in the plugin data directory at session start. Turn off to skip it; the server then runs whatever is already installed there.", + "default": true + } } } diff --git a/plugins/php-lsp/.claude-plugin/plugin.json b/plugins/php-lsp/.claude-plugin/plugin.json index 7d858e3..21d0d0f 100644 --- a/plugins/php-lsp/.claude-plugin/plugin.json +++ b/plugins/php-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\"" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } @@ -28,5 +28,13 @@ ".php": "php" } } + }, + "userConfig": { + "auto_install": { + "type": "boolean", + "title": "Auto-install language server", + "description": "Install and update the language server in the plugin data directory at session start. Turn off to skip it; the server then runs whatever is already installed there.", + "default": true + } } } diff --git a/plugins/prisma-lsp/.claude-plugin/plugin.json b/plugins/prisma-lsp/.claude-plugin/plugin.json index 906e060..6de6632 100644 --- a/plugins/prisma-lsp/.claude-plugin/plugin.json +++ b/plugins/prisma-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\"" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } @@ -28,5 +28,13 @@ ".prisma": "prisma" } } + }, + "userConfig": { + "auto_install": { + "type": "boolean", + "title": "Auto-install language server", + "description": "Install and update the language server in the plugin data directory at session start. Turn off to skip it; the server then runs whatever is already installed there.", + "default": true + } } } diff --git a/plugins/pyright-lsp/.claude-plugin/plugin.json b/plugins/pyright-lsp/.claude-plugin/plugin.json index b5d62c3..404015a 100644 --- a/plugins/pyright-lsp/.claude-plugin/plugin.json +++ b/plugins/pyright-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "[ -x \"${CLAUDE_PLUGIN_DATA}/node_modules/.bin/pyright-langserver\" ] && diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\"" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) [ -x \"${CLAUDE_PLUGIN_DATA}/node_modules/.bin/pyright-langserver\" ] && diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } @@ -29,5 +29,13 @@ ".pyi": "python" } } + }, + "userConfig": { + "auto_install": { + "type": "boolean", + "title": "Auto-install language server", + "description": "Install and update the language server in the plugin data directory at session start. Turn off to skip it; the server then runs whatever is already installed there.", + "default": true + } } } diff --git a/plugins/rubocop-lsp/.claude-plugin/plugin.json b/plugins/rubocop-lsp/.claude-plugin/plugin.json index 0e412fd..2225aa0 100644 --- a/plugins/rubocop-lsp/.claude-plugin/plugin.json +++ b/plugins/rubocop-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "[ -x \"${CLAUDE_PLUGIN_DATA}/node_modules/.bin/code\" ] && diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\"" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) [ -x \"${CLAUDE_PLUGIN_DATA}/node_modules/.bin/code\" ] && diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } @@ -32,5 +32,13 @@ ".ru": "ruby" } } + }, + "userConfig": { + "auto_install": { + "type": "boolean", + "title": "Auto-install language server", + "description": "Install and update the language server in the plugin data directory at session start. Turn off to skip it; the server then runs whatever is already installed there.", + "default": true + } } } diff --git a/plugins/svelte-lsp/.claude-plugin/plugin.json b/plugins/svelte-lsp/.claude-plugin/plugin.json index 8c25b85..5d863e2 100644 --- a/plugins/svelte-lsp/.claude-plugin/plugin.json +++ b/plugins/svelte-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\"" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } @@ -28,5 +28,13 @@ ".svelte": "svelte" } } + }, + "userConfig": { + "auto_install": { + "type": "boolean", + "title": "Auto-install language server", + "description": "Install and update the language server in the plugin data directory at session start. Turn off to skip it; the server then runs whatever is already installed there.", + "default": true + } } } diff --git a/plugins/terraform-lsp/.claude-plugin/plugin.json b/plugins/terraform-lsp/.claude-plugin/plugin.json index defc879..d7998a6 100644 --- a/plugins/terraform-lsp/.claude-plugin/plugin.json +++ b/plugins/terraform-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\"" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } @@ -30,5 +30,13 @@ ".tfvars": "terraform-vars" } } + }, + "userConfig": { + "auto_install": { + "type": "boolean", + "title": "Auto-install language server", + "description": "Install and update the language server in the plugin data directory at session start. Turn off to skip it; the server then runs whatever is already installed there.", + "default": true + } } } diff --git a/plugins/texlab-lsp/.claude-plugin/plugin.json b/plugins/texlab-lsp/.claude-plugin/plugin.json index 6e377fd..251c909 100644 --- a/plugins/texlab-lsp/.claude-plugin/plugin.json +++ b/plugins/texlab-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\"" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } @@ -30,5 +30,13 @@ ".bib": "bibtex" } } + }, + "userConfig": { + "auto_install": { + "type": "boolean", + "title": "Auto-install language server", + "description": "Install and update the language server in the plugin data directory at session start. Turn off to skip it; the server then runs whatever is already installed there.", + "default": true + } } } diff --git a/plugins/typescript-lsp/.claude-plugin/plugin.json b/plugins/typescript-lsp/.claude-plugin/plugin.json index 9b33478..4bbb271 100644 --- a/plugins/typescript-lsp/.claude-plugin/plugin.json +++ b/plugins/typescript-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\"" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } @@ -35,5 +35,13 @@ ".cts": "typescript" } } + }, + "userConfig": { + "auto_install": { + "type": "boolean", + "title": "Auto-install language server", + "description": "Install and update the language server in the plugin data directory at session start. Turn off to skip it; the server then runs whatever is already installed there.", + "default": true + } } } diff --git a/plugins/vue-lsp/.claude-plugin/plugin.json b/plugins/vue-lsp/.claude-plugin/plugin.json index ce711ed..a43966d 100644 --- a/plugins/vue-lsp/.claude-plugin/plugin.json +++ b/plugins/vue-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\"" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } @@ -36,5 +36,13 @@ } } } + }, + "userConfig": { + "auto_install": { + "type": "boolean", + "title": "Auto-install language server", + "description": "Install and update the language server in the plugin data directory at session start. Turn off to skip it; the server then runs whatever is already installed there.", + "default": true + } } } diff --git a/plugins/yaml-lsp/.claude-plugin/plugin.json b/plugins/yaml-lsp/.claude-plugin/plugin.json index 61cdc59..38ba76d 100644 --- a/plugins/yaml-lsp/.claude-plugin/plugin.json +++ b/plugins/yaml-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\"" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } @@ -29,5 +29,13 @@ ".yml": "yaml" } } + }, + "userConfig": { + "auto_install": { + "type": "boolean", + "title": "Auto-install language server", + "description": "Install and update the language server in the plugin data directory at session start. Turn off to skip it; the server then runs whatever is already installed there.", + "default": true + } } } diff --git a/plugins/zls-lsp/.claude-plugin/plugin.json b/plugins/zls-lsp/.claude-plugin/plugin.json index 803bfcd..463919f 100644 --- a/plugins/zls-lsp/.claude-plugin/plugin.json +++ b/plugins/zls-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\"" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } @@ -30,5 +30,13 @@ ".zon": "zig" } } + }, + "userConfig": { + "auto_install": { + "type": "boolean", + "title": "Auto-install language server", + "description": "Install and update the language server in the plugin data directory at session start. Turn off to skip it; the server then runs whatever is already installed there.", + "default": true + } } } From 6376194456e2fa9d53e2aa5c06ed3153c00dfc68 Mon Sep 17 00:00:00 2001 From: Minsu Lee <1964421+amondnet@users.noreply.github.com> Date: Sun, 22 Nov 2026 12:10:59 +0900 Subject: [PATCH 2/4] feat(plugins): auto-install gopls, rust-analyzer, ocaml-lsp, biome and oxlint --- plugins/biome-lsp/.claude-plugin/plugin.json | 20 +++++++++++++++ plugins/biome-lsp/package.json | 6 +++++ plugins/biome-lsp/scripts/lsp.sh | 1 + plugins/gopls-lsp/.claude-plugin/plugin.json | 25 +++++++++++++++++-- plugins/gopls-lsp/scripts/lsp.sh | 6 +++++ plugins/ocaml-lsp/.claude-plugin/plugin.json | 21 ++++++++++++++++ plugins/oxlint-lsp/.claude-plugin/plugin.json | 20 +++++++++++++++ plugins/oxlint-lsp/package.json | 6 +++++ plugins/oxlint-lsp/scripts/lsp.sh | 1 + .../.claude-plugin/plugin.json | 21 ++++++++++++++++ 10 files changed, 125 insertions(+), 2 deletions(-) create mode 100644 plugins/biome-lsp/package.json create mode 100755 plugins/gopls-lsp/scripts/lsp.sh create mode 100644 plugins/oxlint-lsp/package.json diff --git a/plugins/biome-lsp/.claude-plugin/plugin.json b/plugins/biome-lsp/.claude-plugin/plugin.json index 51d3980..86e1b3f 100644 --- a/plugins/biome-lsp/.claude-plugin/plugin.json +++ b/plugins/biome-lsp/.claude-plugin/plugin.json @@ -6,6 +6,18 @@ "author": { "name": "PassionFactory" }, + "hooks": { + "SessionStart": [ + { + "hooks": [ + { + "type": "command", + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" + } + ] + } + ] + }, "lspServers": { "biome": { "command": "bash", @@ -32,5 +44,13 @@ ".html": "html" } } + }, + "userConfig": { + "auto_install": { + "type": "boolean", + "title": "Auto-install language server", + "description": "Install @biomejs/biome into the plugin data directory at session start, used only when the project has no local biome and none is on PATH. Turn off to skip it.", + "default": true + } } } diff --git a/plugins/biome-lsp/package.json b/plugins/biome-lsp/package.json new file mode 100644 index 0000000..1716932 --- /dev/null +++ b/plugins/biome-lsp/package.json @@ -0,0 +1,6 @@ +{ + "private": true, + "dependencies": { + "@biomejs/biome": "2.6.2" + } +} diff --git a/plugins/biome-lsp/scripts/lsp.sh b/plugins/biome-lsp/scripts/lsp.sh index b0b7a74..b771185 100755 --- a/plugins/biome-lsp/scripts/lsp.sh +++ b/plugins/biome-lsp/scripts/lsp.sh @@ -2,5 +2,6 @@ set -euo pipefail if [ -x "./node_modules/.bin/biome" ]; then exec ./node_modules/.bin/biome lsp-proxy --stdio; fi if command -v biome &>/dev/null; then exec biome lsp-proxy --stdio; fi +if [ -x "${CLAUDE_PLUGIN_DATA:-}/node_modules/.bin/biome" ]; then exec "${CLAUDE_PLUGIN_DATA}/node_modules/.bin/biome" lsp-proxy --stdio; fi echo "[biome-lsp] biome not found. Install: npm install --save-dev @biomejs/biome" >&2 exit 1 diff --git a/plugins/gopls-lsp/.claude-plugin/plugin.json b/plugins/gopls-lsp/.claude-plugin/plugin.json index 9c940fd..9684e11 100644 --- a/plugins/gopls-lsp/.claude-plugin/plugin.json +++ b/plugins/gopls-lsp/.claude-plugin/plugin.json @@ -6,15 +6,36 @@ "author": { "name": "PassionFactory" }, + "hooks": { + "SessionStart": [ + { + "hooks": [ + { + "type": "command", + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) command -v gopls >/dev/null 2>&1 || [ -x \"${CLAUDE_PLUGIN_DATA}/bin/gopls\" ] || ! command -v go >/dev/null 2>&1 || GOBIN=\"${CLAUDE_PLUGIN_DATA}/bin\" go install golang.org/x/tools/gopls@latest || true ;; esac", + "timeout": 300 + } + ] + } + ] + }, "lspServers": { "gopls": { - "command": "gopls", + "command": "bash", "args": [ - "serve" + "${CLAUDE_PLUGIN_ROOT}/scripts/lsp.sh" ], "extensionToLanguage": { ".go": "go" } } + }, + "userConfig": { + "auto_install": { + "type": "boolean", + "title": "Auto-install language server", + "description": "When gopls is not on PATH, install it into the plugin data directory with `go install` at session start (requires Go). Turn off to manage gopls yourself.", + "default": true + } } } diff --git a/plugins/gopls-lsp/scripts/lsp.sh b/plugins/gopls-lsp/scripts/lsp.sh new file mode 100755 index 0000000..296d5f6 --- /dev/null +++ b/plugins/gopls-lsp/scripts/lsp.sh @@ -0,0 +1,6 @@ +#!/usr/bin/env bash +set -euo pipefail +if command -v gopls &>/dev/null; then exec gopls serve; fi +if [ -x "${CLAUDE_PLUGIN_DATA:-}/bin/gopls" ]; then exec "${CLAUDE_PLUGIN_DATA}/bin/gopls" serve; fi +echo "[gopls-lsp] gopls not found. Install: go install golang.org/x/tools/gopls@latest" >&2 +exit 1 diff --git a/plugins/ocaml-lsp/.claude-plugin/plugin.json b/plugins/ocaml-lsp/.claude-plugin/plugin.json index ecfb200..4e55bfc 100644 --- a/plugins/ocaml-lsp/.claude-plugin/plugin.json +++ b/plugins/ocaml-lsp/.claude-plugin/plugin.json @@ -6,6 +6,19 @@ "author": { "name": "PassionFactory" }, + "hooks": { + "SessionStart": [ + { + "hooks": [ + { + "type": "command", + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) command -v ocamllsp >/dev/null 2>&1 || ! command -v opam >/dev/null 2>&1 || opam install -y ocaml-lsp-server || true ;; esac", + "timeout": 600 + } + ] + } + ] + }, "lspServers": { "ocaml": { "command": "ocamllsp", @@ -15,5 +28,13 @@ ".mli": "ocaml" } } + }, + "userConfig": { + "auto_install": { + "type": "boolean", + "title": "Auto-install language server", + "description": "When ocamllsp is not on PATH, install ocaml-lsp-server into the current opam switch at session start (requires opam; the first build can take minutes). Turn off to manage ocamllsp yourself.", + "default": true + } } } diff --git a/plugins/oxlint-lsp/.claude-plugin/plugin.json b/plugins/oxlint-lsp/.claude-plugin/plugin.json index cc6d6f8..0eb1133 100644 --- a/plugins/oxlint-lsp/.claude-plugin/plugin.json +++ b/plugins/oxlint-lsp/.claude-plugin/plugin.json @@ -6,6 +6,18 @@ "author": { "name": "PassionFactory" }, + "hooks": { + "SessionStart": [ + { + "hooks": [ + { + "type": "command", + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" + } + ] + } + ] + }, "lspServers": { "oxlint": { "command": "bash", @@ -26,5 +38,13 @@ ".svelte": "svelte" } } + }, + "userConfig": { + "auto_install": { + "type": "boolean", + "title": "Auto-install language server", + "description": "Install oxlint into the plugin data directory at session start, used only when the project has no local oxlint and none is on PATH. Turn off to skip it.", + "default": true + } } } diff --git a/plugins/oxlint-lsp/package.json b/plugins/oxlint-lsp/package.json new file mode 100644 index 0000000..b7055ef --- /dev/null +++ b/plugins/oxlint-lsp/package.json @@ -0,0 +1,6 @@ +{ + "private": true, + "dependencies": { + "oxlint": "1.94.0" + } +} diff --git a/plugins/oxlint-lsp/scripts/lsp.sh b/plugins/oxlint-lsp/scripts/lsp.sh index ed0dbde..6926a3c 100755 --- a/plugins/oxlint-lsp/scripts/lsp.sh +++ b/plugins/oxlint-lsp/scripts/lsp.sh @@ -4,5 +4,6 @@ if [ -x "./node_modules/.bin/oxc_language_server" ]; then exec ./node_modules/.b if command -v oxc_language_server &>/dev/null; then exec oxc_language_server; fi if [ -x "./node_modules/.bin/oxlint" ]; then exec ./node_modules/.bin/oxlint --lsp; fi if command -v oxlint &>/dev/null; then exec oxlint --lsp; fi +if [ -x "${CLAUDE_PLUGIN_DATA:-}/node_modules/.bin/oxlint" ]; then exec "${CLAUDE_PLUGIN_DATA}/node_modules/.bin/oxlint" --lsp; fi echo "[oxlint-lsp] oxlint/oxc_language_server not found. Install: npm install --save-dev oxlint" >&2 exit 1 diff --git a/plugins/rust-analyzer-lsp/.claude-plugin/plugin.json b/plugins/rust-analyzer-lsp/.claude-plugin/plugin.json index 934efeb..dc686cd 100644 --- a/plugins/rust-analyzer-lsp/.claude-plugin/plugin.json +++ b/plugins/rust-analyzer-lsp/.claude-plugin/plugin.json @@ -6,6 +6,19 @@ "author": { "name": "PassionFactory" }, + "hooks": { + "SessionStart": [ + { + "hooks": [ + { + "type": "command", + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) rust-analyzer --version >/dev/null 2>&1 || ! command -v rustup >/dev/null 2>&1 || rustup component add rust-analyzer || true ;; esac", + "timeout": 300 + } + ] + } + ] + }, "lspServers": { "rust-analyzer": { "command": "rust-analyzer", @@ -14,5 +27,13 @@ ".rs": "rust" } } + }, + "userConfig": { + "auto_install": { + "type": "boolean", + "title": "Auto-install language server", + "description": "When rust-analyzer cannot run, add it with `rustup component add rust-analyzer` at session start (requires rustup). Turn off to manage rust-analyzer yourself.", + "default": true + } } } From 15d0a7e7e0e7346f70e53f9153b273f8032b6ec2 Mon Sep 17 00:00:00 2001 From: Minsu Lee <1964421+amondnet@users.noreply.github.com> Date: Sun, 22 Nov 2026 12:11:00 +0900 Subject: [PATCH 3/4] docs: document LSP auto-install and the auto_install option --- ARCHITECTURE.md | 12 ++++++++---- README.md | 13 +++++++++++-- 2 files changed, 19 insertions(+), 6 deletions(-) diff --git a/ARCHITECTURE.md b/ARCHITECTURE.md index 0af672a..c4d04a9 100644 --- a/ARCHITECTURE.md +++ b/ARCHITECTURE.md @@ -196,10 +196,14 @@ under `~/.cache/dora/`. ### `plugins/` — LSP Server Plugins -32 LSP server plugin directories (plus `dora-jetbrains-plugin` for IDE -integration), each containing a `package.json` that declares dependencies. -LSP plugins are auto-installed via `npm install` into `$CLAUDE_PLUGIN_DATA` -on first session start. +33 LSP server plugin directories (plus `dora-jetbrains-plugin` for IDE +integration). 27 of them carry a `package.json` that declares their npm +dependencies; the rest run a toolchain-provided server. +LSP plugins are auto-installed into `$CLAUDE_PLUGIN_DATA` by a SessionStart +hook (`npm install`, or `go install` / `rustup` / `opam` for toolchain-based +servers). Every installing plugin declares a `userConfig.auto_install` boolean +(default `true`); the hook reads it as `CLAUDE_PLUGIN_OPTION_AUTO_INSTALL` and +skips the install when it is off. Example (`plugins/typescript-lsp/package.json`): ```json diff --git a/README.md b/README.md index d6ab9c1..07833d9 100644 --- a/README.md +++ b/README.md @@ -37,8 +37,17 @@ Install only the language servers you need: /plugin install rust-analyzer-lsp@code-intelligence ``` -> **Note:** Language server binaries are auto-installed via `npm install` on first session start. -> No manual binary installation is required. +> **Note:** Language servers are auto-installed at session start, so you don't install them by hand: +> +> - **npm-based servers** (including the biome and oxlint fallbacks): `npm install` into the +> plugin data directory on first start and whenever the plugin's `package.json` changes. +> - **`gopls`**: `go install`, **`rust-analyzer`**: `rustup component add`, **`ocamllsp`**: +> `opam install`. Each runs only when the server is missing and its toolchain (Go, rustup, +> opam) is on `PATH`. +> - **`deno`, `gleam`, `sourcekit-lsp`**: ship with their toolchains and are not installed. +> +> Each installing plugin has an **Auto-install language server** option (`auto_install`, default +> on). Turn it off in `/config` to stop session-start installs and updates for that plugin. ### Plugin management From 42cfa68e002e62c69bf26867e99f4ce18f079062 Mon Sep 17 00:00:00 2001 From: Minsu Lee <1964421+amondnet@users.noreply.github.com> Date: Sun, 22 Nov 2026 12:47:32 +0900 Subject: [PATCH 4/4] chore(plugins): apply AI code review suggestions - Launch ocaml-lsp through scripts/lsp.sh with an `opam exec --` fallback, and skip the install when the switch already provides ocamllsp - Match the auto_install opt-out case-insensitively - Reinstall biome/oxlint when the manifest matches but the binary is gone - Guard every install hook and wrapper against an empty CLAUDE_PLUGIN_DATA - Correct where toolchain-based servers install in ARCHITECTURE.md --- ARCHITECTURE.md | 11 +++++++---- plugins/astro-lsp/.claude-plugin/plugin.json | 2 +- plugins/bash-lsp/.claude-plugin/plugin.json | 2 +- plugins/biome-lsp/.claude-plugin/plugin.json | 2 +- plugins/biome-lsp/scripts/lsp.sh | 2 +- plugins/clangd-lsp/.claude-plugin/plugin.json | 2 +- .../code-intelligence-lsp/.claude-plugin/plugin.json | 2 +- plugins/csharp-lsp/.claude-plugin/plugin.json | 2 +- plugins/dart-lsp/.claude-plugin/plugin.json | 2 +- plugins/dockerfile-lsp/.claude-plugin/plugin.json | 2 +- plugins/elixir-lsp/.claude-plugin/plugin.json | 2 +- plugins/eslint-lsp/.claude-plugin/plugin.json | 2 +- plugins/fsharp-lsp/.claude-plugin/plugin.json | 2 +- plugins/gopls-lsp/.claude-plugin/plugin.json | 2 +- plugins/gopls-lsp/scripts/lsp.sh | 2 +- plugins/graphql-lsp/.claude-plugin/plugin.json | 2 +- plugins/jdtls-lsp/.claude-plugin/plugin.json | 2 +- plugins/kotlin-lsp/.claude-plugin/plugin.json | 2 +- plugins/lua-lsp/.claude-plugin/plugin.json | 2 +- plugins/ocaml-lsp/.claude-plugin/plugin.json | 10 ++++++---- plugins/ocaml-lsp/scripts/lsp.sh | 6 ++++++ plugins/oxlint-lsp/.claude-plugin/plugin.json | 2 +- plugins/oxlint-lsp/scripts/lsp.sh | 2 +- plugins/php-lsp/.claude-plugin/plugin.json | 2 +- plugins/prisma-lsp/.claude-plugin/plugin.json | 2 +- plugins/pyright-lsp/.claude-plugin/plugin.json | 2 +- plugins/rubocop-lsp/.claude-plugin/plugin.json | 2 +- plugins/rust-analyzer-lsp/.claude-plugin/plugin.json | 2 +- plugins/svelte-lsp/.claude-plugin/plugin.json | 2 +- plugins/terraform-lsp/.claude-plugin/plugin.json | 2 +- plugins/texlab-lsp/.claude-plugin/plugin.json | 2 +- plugins/typescript-lsp/.claude-plugin/plugin.json | 2 +- plugins/vue-lsp/.claude-plugin/plugin.json | 2 +- plugins/yaml-lsp/.claude-plugin/plugin.json | 2 +- plugins/zls-lsp/.claude-plugin/plugin.json | 2 +- 35 files changed, 51 insertions(+), 40 deletions(-) create mode 100755 plugins/ocaml-lsp/scripts/lsp.sh diff --git a/ARCHITECTURE.md b/ARCHITECTURE.md index c4d04a9..cf2d2e7 100644 --- a/ARCHITECTURE.md +++ b/ARCHITECTURE.md @@ -198,10 +198,13 @@ under `~/.cache/dora/`. 33 LSP server plugin directories (plus `dora-jetbrains-plugin` for IDE integration). 27 of them carry a `package.json` that declares their npm -dependencies; the rest run a toolchain-provided server. -LSP plugins are auto-installed into `$CLAUDE_PLUGIN_DATA` by a SessionStart -hook (`npm install`, or `go install` / `rustup` / `opam` for toolchain-based -servers). Every installing plugin declares a `userConfig.auto_install` boolean +dependencies; the rest either install through a toolchain (gopls, +rust-analyzer, ocaml-lsp) or ship with one (deno, gleam, swift). +A SessionStart hook auto-installs each server: npm-based plugins run +`npm install` into `$CLAUDE_PLUGIN_DATA`, gopls uses `go install` into the same +directory, and rust-analyzer and ocaml-lsp install into the active rustup +toolchain and opam switch. Every installing plugin declares a +`userConfig.auto_install` boolean (default `true`); the hook reads it as `CLAUDE_PLUGIN_OPTION_AUTO_INSTALL` and skips the install when it is off. diff --git a/plugins/astro-lsp/.claude-plugin/plugin.json b/plugins/astro-lsp/.claude-plugin/plugin.json index ae544ff..1968941 100644 --- a/plugins/astro-lsp/.claude-plugin/plugin.json +++ b/plugins/astro-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in [fF][aA][lL][sS][eE]|0|[nN][oO]|[oO][fF][fF]) ;; *) [ -n \"${CLAUDE_PLUGIN_DATA:-}\" ] || exit 0; diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } diff --git a/plugins/bash-lsp/.claude-plugin/plugin.json b/plugins/bash-lsp/.claude-plugin/plugin.json index 5d26ac9..77d8251 100644 --- a/plugins/bash-lsp/.claude-plugin/plugin.json +++ b/plugins/bash-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) [ -x \"${CLAUDE_PLUGIN_DATA}/node_modules/.bin/bash-language-server\" ] && diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in [fF][aA][lL][sS][eE]|0|[nN][oO]|[oO][fF][fF]) ;; *) [ -n \"${CLAUDE_PLUGIN_DATA:-}\" ] || exit 0; [ -x \"${CLAUDE_PLUGIN_DATA}/node_modules/.bin/bash-language-server\" ] && diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } diff --git a/plugins/biome-lsp/.claude-plugin/plugin.json b/plugins/biome-lsp/.claude-plugin/plugin.json index 86e1b3f..149cf8c 100644 --- a/plugins/biome-lsp/.claude-plugin/plugin.json +++ b/plugins/biome-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in [fF][aA][lL][sS][eE]|0|[nN][oO]|[oO][fF][fF]) ;; *) [ -n \"${CLAUDE_PLUGIN_DATA:-}\" ] || exit 0; [ -x \"${CLAUDE_PLUGIN_DATA}/node_modules/.bin/biome\" ] && diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } diff --git a/plugins/biome-lsp/scripts/lsp.sh b/plugins/biome-lsp/scripts/lsp.sh index b771185..39df978 100755 --- a/plugins/biome-lsp/scripts/lsp.sh +++ b/plugins/biome-lsp/scripts/lsp.sh @@ -2,6 +2,6 @@ set -euo pipefail if [ -x "./node_modules/.bin/biome" ]; then exec ./node_modules/.bin/biome lsp-proxy --stdio; fi if command -v biome &>/dev/null; then exec biome lsp-proxy --stdio; fi -if [ -x "${CLAUDE_PLUGIN_DATA:-}/node_modules/.bin/biome" ]; then exec "${CLAUDE_PLUGIN_DATA}/node_modules/.bin/biome" lsp-proxy --stdio; fi +if [ -n "${CLAUDE_PLUGIN_DATA:-}" ] && [ -x "${CLAUDE_PLUGIN_DATA}/node_modules/.bin/biome" ]; then exec "${CLAUDE_PLUGIN_DATA}/node_modules/.bin/biome" lsp-proxy --stdio; fi echo "[biome-lsp] biome not found. Install: npm install --save-dev @biomejs/biome" >&2 exit 1 diff --git a/plugins/clangd-lsp/.claude-plugin/plugin.json b/plugins/clangd-lsp/.claude-plugin/plugin.json index c03a26a..9f13033 100644 --- a/plugins/clangd-lsp/.claude-plugin/plugin.json +++ b/plugins/clangd-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) [ -x \"${CLAUDE_PLUGIN_DATA}/node_modules/.bin/code\" ] && diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in [fF][aA][lL][sS][eE]|0|[nN][oO]|[oO][fF][fF]) ;; *) [ -n \"${CLAUDE_PLUGIN_DATA:-}\" ] || exit 0; [ -x \"${CLAUDE_PLUGIN_DATA}/node_modules/.bin/code\" ] && diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } diff --git a/plugins/code-intelligence-lsp/.claude-plugin/plugin.json b/plugins/code-intelligence-lsp/.claude-plugin/plugin.json index 31b61ad..3fe4b29 100644 --- a/plugins/code-intelligence-lsp/.claude-plugin/plugin.json +++ b/plugins/code-intelligence-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in [fF][aA][lL][sS][eE]|0|[nN][oO]|[oO][fF][fF]) ;; *) [ -n \"${CLAUDE_PLUGIN_DATA:-}\" ] || exit 0; diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } diff --git a/plugins/csharp-lsp/.claude-plugin/plugin.json b/plugins/csharp-lsp/.claude-plugin/plugin.json index c5701d1..e0811f6 100644 --- a/plugins/csharp-lsp/.claude-plugin/plugin.json +++ b/plugins/csharp-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in [fF][aA][lL][sS][eE]|0|[nN][oO]|[oO][fF][fF]) ;; *) [ -n \"${CLAUDE_PLUGIN_DATA:-}\" ] || exit 0; diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } diff --git a/plugins/dart-lsp/.claude-plugin/plugin.json b/plugins/dart-lsp/.claude-plugin/plugin.json index 28eb82e..77bdb80 100644 --- a/plugins/dart-lsp/.claude-plugin/plugin.json +++ b/plugins/dart-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) test -x \"${CLAUDE_PLUGIN_DATA}/node_modules/.bin/code\" && diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in [fF][aA][lL][sS][eE]|0|[nN][oO]|[oO][fF][fF]) ;; *) [ -n \"${CLAUDE_PLUGIN_DATA:-}\" ] || exit 0; test -x \"${CLAUDE_PLUGIN_DATA}/node_modules/.bin/code\" && diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } diff --git a/plugins/dockerfile-lsp/.claude-plugin/plugin.json b/plugins/dockerfile-lsp/.claude-plugin/plugin.json index cd10a9b..0602ccd 100644 --- a/plugins/dockerfile-lsp/.claude-plugin/plugin.json +++ b/plugins/dockerfile-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in [fF][aA][lL][sS][eE]|0|[nN][oO]|[oO][fF][fF]) ;; *) [ -n \"${CLAUDE_PLUGIN_DATA:-}\" ] || exit 0; diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } diff --git a/plugins/elixir-lsp/.claude-plugin/plugin.json b/plugins/elixir-lsp/.claude-plugin/plugin.json index de3077f..b954d7d 100644 --- a/plugins/elixir-lsp/.claude-plugin/plugin.json +++ b/plugins/elixir-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || (rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" && false) ;; esac" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in [fF][aA][lL][sS][eE]|0|[nN][oO]|[oO][fF][fF]) ;; *) [ -n \"${CLAUDE_PLUGIN_DATA:-}\" ] || exit 0; diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || (rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" && false) ;; esac" } ] } diff --git a/plugins/eslint-lsp/.claude-plugin/plugin.json b/plugins/eslint-lsp/.claude-plugin/plugin.json index 05c6af2..4f3cc20 100644 --- a/plugins/eslint-lsp/.claude-plugin/plugin.json +++ b/plugins/eslint-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in [fF][aA][lL][sS][eE]|0|[nN][oO]|[oO][fF][fF]) ;; *) [ -n \"${CLAUDE_PLUGIN_DATA:-}\" ] || exit 0; diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } diff --git a/plugins/fsharp-lsp/.claude-plugin/plugin.json b/plugins/fsharp-lsp/.claude-plugin/plugin.json index 8d0e394..47b398c 100644 --- a/plugins/fsharp-lsp/.claude-plugin/plugin.json +++ b/plugins/fsharp-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) ([ -x \"${CLAUDE_PLUGIN_DATA}/node_modules/.bin/code\" ] && diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1) || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in [fF][aA][lL][sS][eE]|0|[nN][oO]|[oO][fF][fF]) ;; *) [ -n \"${CLAUDE_PLUGIN_DATA:-}\" ] || exit 0; ([ -x \"${CLAUDE_PLUGIN_DATA}/node_modules/.bin/code\" ] && diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1) || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } diff --git a/plugins/gopls-lsp/.claude-plugin/plugin.json b/plugins/gopls-lsp/.claude-plugin/plugin.json index 9684e11..b42e529 100644 --- a/plugins/gopls-lsp/.claude-plugin/plugin.json +++ b/plugins/gopls-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) command -v gopls >/dev/null 2>&1 || [ -x \"${CLAUDE_PLUGIN_DATA}/bin/gopls\" ] || ! command -v go >/dev/null 2>&1 || GOBIN=\"${CLAUDE_PLUGIN_DATA}/bin\" go install golang.org/x/tools/gopls@latest || true ;; esac", + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in [fF][aA][lL][sS][eE]|0|[nN][oO]|[oO][fF][fF]) ;; *) command -v gopls >/dev/null 2>&1 || { [ -n \"${CLAUDE_PLUGIN_DATA:-}\" ] && [ -x \"${CLAUDE_PLUGIN_DATA}/bin/gopls\" ]; } || ! command -v go >/dev/null 2>&1 || [ -z \"${CLAUDE_PLUGIN_DATA:-}\" ] || GOBIN=\"${CLAUDE_PLUGIN_DATA}/bin\" go install golang.org/x/tools/gopls@latest || true ;; esac", "timeout": 300 } ] diff --git a/plugins/gopls-lsp/scripts/lsp.sh b/plugins/gopls-lsp/scripts/lsp.sh index 296d5f6..696ba2f 100755 --- a/plugins/gopls-lsp/scripts/lsp.sh +++ b/plugins/gopls-lsp/scripts/lsp.sh @@ -1,6 +1,6 @@ #!/usr/bin/env bash set -euo pipefail if command -v gopls &>/dev/null; then exec gopls serve; fi -if [ -x "${CLAUDE_PLUGIN_DATA:-}/bin/gopls" ]; then exec "${CLAUDE_PLUGIN_DATA}/bin/gopls" serve; fi +if [ -n "${CLAUDE_PLUGIN_DATA:-}" ] && [ -x "${CLAUDE_PLUGIN_DATA}/bin/gopls" ]; then exec "${CLAUDE_PLUGIN_DATA}/bin/gopls" serve; fi echo "[gopls-lsp] gopls not found. Install: go install golang.org/x/tools/gopls@latest" >&2 exit 1 diff --git a/plugins/graphql-lsp/.claude-plugin/plugin.json b/plugins/graphql-lsp/.claude-plugin/plugin.json index 9e18b19..a918577 100644 --- a/plugins/graphql-lsp/.claude-plugin/plugin.json +++ b/plugins/graphql-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in [fF][aA][lL][sS][eE]|0|[nN][oO]|[oO][fF][fF]) ;; *) [ -n \"${CLAUDE_PLUGIN_DATA:-}\" ] || exit 0; diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } diff --git a/plugins/jdtls-lsp/.claude-plugin/plugin.json b/plugins/jdtls-lsp/.claude-plugin/plugin.json index 1672534..41271ce 100644 --- a/plugins/jdtls-lsp/.claude-plugin/plugin.json +++ b/plugins/jdtls-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || (rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" && exit 1) ;; esac" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in [fF][aA][lL][sS][eE]|0|[nN][oO]|[oO][fF][fF]) ;; *) [ -n \"${CLAUDE_PLUGIN_DATA:-}\" ] || exit 0; diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || (rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" && exit 1) ;; esac" } ] } diff --git a/plugins/kotlin-lsp/.claude-plugin/plugin.json b/plugins/kotlin-lsp/.claude-plugin/plugin.json index aebe15d..d23fd3c 100644 --- a/plugins/kotlin-lsp/.claude-plugin/plugin.json +++ b/plugins/kotlin-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in [fF][aA][lL][sS][eE]|0|[nN][oO]|[oO][fF][fF]) ;; *) [ -n \"${CLAUDE_PLUGIN_DATA:-}\" ] || exit 0; diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } diff --git a/plugins/lua-lsp/.claude-plugin/plugin.json b/plugins/lua-lsp/.claude-plugin/plugin.json index e75f05e..fbc8931 100644 --- a/plugins/lua-lsp/.claude-plugin/plugin.json +++ b/plugins/lua-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in [fF][aA][lL][sS][eE]|0|[nN][oO]|[oO][fF][fF]) ;; *) [ -n \"${CLAUDE_PLUGIN_DATA:-}\" ] || exit 0; diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } diff --git a/plugins/ocaml-lsp/.claude-plugin/plugin.json b/plugins/ocaml-lsp/.claude-plugin/plugin.json index 4e55bfc..cc8f71a 100644 --- a/plugins/ocaml-lsp/.claude-plugin/plugin.json +++ b/plugins/ocaml-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) command -v ocamllsp >/dev/null 2>&1 || ! command -v opam >/dev/null 2>&1 || opam install -y ocaml-lsp-server || true ;; esac", + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in [fF][aA][lL][sS][eE]|0|[nN][oO]|[oO][fF][fF]) ;; *) command -v ocamllsp >/dev/null 2>&1 || ! command -v opam >/dev/null 2>&1 || opam exec -- ocamllsp --version >/dev/null 2>&1 || opam install -y ocaml-lsp-server || true ;; esac", "timeout": 600 } ] @@ -21,8 +21,10 @@ }, "lspServers": { "ocaml": { - "command": "ocamllsp", - "args": [], + "command": "bash", + "args": [ + "${CLAUDE_PLUGIN_ROOT}/scripts/lsp.sh" + ], "extensionToLanguage": { ".ml": "ocaml", ".mli": "ocaml" @@ -33,7 +35,7 @@ "auto_install": { "type": "boolean", "title": "Auto-install language server", - "description": "When ocamllsp is not on PATH, install ocaml-lsp-server into the current opam switch at session start (requires opam; the first build can take minutes). Turn off to manage ocamllsp yourself.", + "description": "When ocamllsp is not available, install ocaml-lsp-server into the current opam switch at session start (requires opam; the first build can take minutes). Turn off to manage ocamllsp yourself.", "default": true } } diff --git a/plugins/ocaml-lsp/scripts/lsp.sh b/plugins/ocaml-lsp/scripts/lsp.sh new file mode 100755 index 0000000..c16a59a --- /dev/null +++ b/plugins/ocaml-lsp/scripts/lsp.sh @@ -0,0 +1,6 @@ +#!/usr/bin/env bash +set -euo pipefail +if command -v ocamllsp &>/dev/null; then exec ocamllsp; fi +if command -v opam &>/dev/null && opam exec -- ocamllsp --version &>/dev/null; then exec opam exec -- ocamllsp; fi +echo "[ocaml-lsp] ocamllsp not found. Install: opam install ocaml-lsp-server" >&2 +exit 1 diff --git a/plugins/oxlint-lsp/.claude-plugin/plugin.json b/plugins/oxlint-lsp/.claude-plugin/plugin.json index 0eb1133..830ce88 100644 --- a/plugins/oxlint-lsp/.claude-plugin/plugin.json +++ b/plugins/oxlint-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in [fF][aA][lL][sS][eE]|0|[nN][oO]|[oO][fF][fF]) ;; *) [ -n \"${CLAUDE_PLUGIN_DATA:-}\" ] || exit 0; [ -x \"${CLAUDE_PLUGIN_DATA}/node_modules/.bin/oxlint\" ] && diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } diff --git a/plugins/oxlint-lsp/scripts/lsp.sh b/plugins/oxlint-lsp/scripts/lsp.sh index 6926a3c..6b427cd 100755 --- a/plugins/oxlint-lsp/scripts/lsp.sh +++ b/plugins/oxlint-lsp/scripts/lsp.sh @@ -4,6 +4,6 @@ if [ -x "./node_modules/.bin/oxc_language_server" ]; then exec ./node_modules/.b if command -v oxc_language_server &>/dev/null; then exec oxc_language_server; fi if [ -x "./node_modules/.bin/oxlint" ]; then exec ./node_modules/.bin/oxlint --lsp; fi if command -v oxlint &>/dev/null; then exec oxlint --lsp; fi -if [ -x "${CLAUDE_PLUGIN_DATA:-}/node_modules/.bin/oxlint" ]; then exec "${CLAUDE_PLUGIN_DATA}/node_modules/.bin/oxlint" --lsp; fi +if [ -n "${CLAUDE_PLUGIN_DATA:-}" ] && [ -x "${CLAUDE_PLUGIN_DATA}/node_modules/.bin/oxlint" ]; then exec "${CLAUDE_PLUGIN_DATA}/node_modules/.bin/oxlint" --lsp; fi echo "[oxlint-lsp] oxlint/oxc_language_server not found. Install: npm install --save-dev oxlint" >&2 exit 1 diff --git a/plugins/php-lsp/.claude-plugin/plugin.json b/plugins/php-lsp/.claude-plugin/plugin.json index 21d0d0f..c5dec40 100644 --- a/plugins/php-lsp/.claude-plugin/plugin.json +++ b/plugins/php-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in [fF][aA][lL][sS][eE]|0|[nN][oO]|[oO][fF][fF]) ;; *) [ -n \"${CLAUDE_PLUGIN_DATA:-}\" ] || exit 0; diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } diff --git a/plugins/prisma-lsp/.claude-plugin/plugin.json b/plugins/prisma-lsp/.claude-plugin/plugin.json index 6de6632..4308771 100644 --- a/plugins/prisma-lsp/.claude-plugin/plugin.json +++ b/plugins/prisma-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in [fF][aA][lL][sS][eE]|0|[nN][oO]|[oO][fF][fF]) ;; *) [ -n \"${CLAUDE_PLUGIN_DATA:-}\" ] || exit 0; diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } diff --git a/plugins/pyright-lsp/.claude-plugin/plugin.json b/plugins/pyright-lsp/.claude-plugin/plugin.json index 404015a..2700f35 100644 --- a/plugins/pyright-lsp/.claude-plugin/plugin.json +++ b/plugins/pyright-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) [ -x \"${CLAUDE_PLUGIN_DATA}/node_modules/.bin/pyright-langserver\" ] && diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in [fF][aA][lL][sS][eE]|0|[nN][oO]|[oO][fF][fF]) ;; *) [ -n \"${CLAUDE_PLUGIN_DATA:-}\" ] || exit 0; [ -x \"${CLAUDE_PLUGIN_DATA}/node_modules/.bin/pyright-langserver\" ] && diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } diff --git a/plugins/rubocop-lsp/.claude-plugin/plugin.json b/plugins/rubocop-lsp/.claude-plugin/plugin.json index 2225aa0..a859472 100644 --- a/plugins/rubocop-lsp/.claude-plugin/plugin.json +++ b/plugins/rubocop-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) [ -x \"${CLAUDE_PLUGIN_DATA}/node_modules/.bin/code\" ] && diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in [fF][aA][lL][sS][eE]|0|[nN][oO]|[oO][fF][fF]) ;; *) [ -n \"${CLAUDE_PLUGIN_DATA:-}\" ] || exit 0; [ -x \"${CLAUDE_PLUGIN_DATA}/node_modules/.bin/code\" ] && diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } diff --git a/plugins/rust-analyzer-lsp/.claude-plugin/plugin.json b/plugins/rust-analyzer-lsp/.claude-plugin/plugin.json index dc686cd..8e7813b 100644 --- a/plugins/rust-analyzer-lsp/.claude-plugin/plugin.json +++ b/plugins/rust-analyzer-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) rust-analyzer --version >/dev/null 2>&1 || ! command -v rustup >/dev/null 2>&1 || rustup component add rust-analyzer || true ;; esac", + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in [fF][aA][lL][sS][eE]|0|[nN][oO]|[oO][fF][fF]) ;; *) rust-analyzer --version >/dev/null 2>&1 || ! command -v rustup >/dev/null 2>&1 || rustup component add rust-analyzer || true ;; esac", "timeout": 300 } ] diff --git a/plugins/svelte-lsp/.claude-plugin/plugin.json b/plugins/svelte-lsp/.claude-plugin/plugin.json index 5d863e2..1e077e1 100644 --- a/plugins/svelte-lsp/.claude-plugin/plugin.json +++ b/plugins/svelte-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in [fF][aA][lL][sS][eE]|0|[nN][oO]|[oO][fF][fF]) ;; *) [ -n \"${CLAUDE_PLUGIN_DATA:-}\" ] || exit 0; diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } diff --git a/plugins/terraform-lsp/.claude-plugin/plugin.json b/plugins/terraform-lsp/.claude-plugin/plugin.json index d7998a6..95b50ed 100644 --- a/plugins/terraform-lsp/.claude-plugin/plugin.json +++ b/plugins/terraform-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in [fF][aA][lL][sS][eE]|0|[nN][oO]|[oO][fF][fF]) ;; *) [ -n \"${CLAUDE_PLUGIN_DATA:-}\" ] || exit 0; diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } diff --git a/plugins/texlab-lsp/.claude-plugin/plugin.json b/plugins/texlab-lsp/.claude-plugin/plugin.json index 251c909..edcdf77 100644 --- a/plugins/texlab-lsp/.claude-plugin/plugin.json +++ b/plugins/texlab-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in [fF][aA][lL][sS][eE]|0|[nN][oO]|[oO][fF][fF]) ;; *) [ -n \"${CLAUDE_PLUGIN_DATA:-}\" ] || exit 0; diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } diff --git a/plugins/typescript-lsp/.claude-plugin/plugin.json b/plugins/typescript-lsp/.claude-plugin/plugin.json index 4bbb271..ee9a6b2 100644 --- a/plugins/typescript-lsp/.claude-plugin/plugin.json +++ b/plugins/typescript-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in [fF][aA][lL][sS][eE]|0|[nN][oO]|[oO][fF][fF]) ;; *) [ -n \"${CLAUDE_PLUGIN_DATA:-}\" ] || exit 0; diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } diff --git a/plugins/vue-lsp/.claude-plugin/plugin.json b/plugins/vue-lsp/.claude-plugin/plugin.json index a43966d..8702cb0 100644 --- a/plugins/vue-lsp/.claude-plugin/plugin.json +++ b/plugins/vue-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in [fF][aA][lL][sS][eE]|0|[nN][oO]|[oO][fF][fF]) ;; *) [ -n \"${CLAUDE_PLUGIN_DATA:-}\" ] || exit 0; diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } diff --git a/plugins/yaml-lsp/.claude-plugin/plugin.json b/plugins/yaml-lsp/.claude-plugin/plugin.json index 38ba76d..978f7d3 100644 --- a/plugins/yaml-lsp/.claude-plugin/plugin.json +++ b/plugins/yaml-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in [fF][aA][lL][sS][eE]|0|[nN][oO]|[oO][fF][fF]) ;; *) [ -n \"${CLAUDE_PLUGIN_DATA:-}\" ] || exit 0; diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] } diff --git a/plugins/zls-lsp/.claude-plugin/plugin.json b/plugins/zls-lsp/.claude-plugin/plugin.json index 463919f..8eeccf1 100644 --- a/plugins/zls-lsp/.claude-plugin/plugin.json +++ b/plugins/zls-lsp/.claude-plugin/plugin.json @@ -12,7 +12,7 @@ "hooks": [ { "type": "command", - "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in false|0|no|off) ;; *) diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" + "command": "case \"${CLAUDE_PLUGIN_OPTION_AUTO_INSTALL:-true}\" in [fF][aA][lL][sS][eE]|0|[nN][oO]|[oO][fF][fF]) ;; *) [ -n \"${CLAUDE_PLUGIN_DATA:-}\" ] || exit 0; diff -q \"${CLAUDE_PLUGIN_ROOT}/package.json\" \"${CLAUDE_PLUGIN_DATA}/package.json\" >/dev/null 2>&1 || (cd \"${CLAUDE_PLUGIN_DATA}\" && cp \"${CLAUDE_PLUGIN_ROOT}/package.json\" . && npm install --loglevel=error) || rm -f \"${CLAUDE_PLUGIN_DATA}/package.json\" ;; esac" } ] }