fix(lsp): make intelephense index large PHP repos, add LSP pickers
This commit is contained in:
6 files changed
+60
-34
No files matched your search
@@ -51,6 +51,18 @@ function M.setup()
|
||||
end
|
||||
map("<leader>li", "<cmd>checkhealth vim.lsp<cr>", "LSP info")
|
||||
map("<leader>lr", restart, "Restart LSP servers")
|
||||
-- Location lists in a snacks picker instead of quickfix; a single result jumps directly.
|
||||
for lhs, spec in pairs({
|
||||
grr = { "lsp_references", "References" },
|
||||
gri = { "lsp_implementations", "Implementations" },
|
||||
grt = { "lsp_type_definitions", "Type definitions" },
|
||||
gai = { "lsp_incoming_calls", "Incoming calls" },
|
||||
gao = { "lsp_outgoing_calls", "Outgoing calls" },
|
||||
}) do
|
||||
map(lhs, function()
|
||||
require("snacks").picker[spec[1]]()
|
||||
end, spec[2])
|
||||
end
|
||||
end,
|
||||
})
|
||||
|
||||
|
||||
+5
-10
@@ -1,7 +1,7 @@
|
||||
-- Completion: minuet against a local llama-server, no cloud fallback.
|
||||
-- Completion: minuet against a local Ollama, no cloud fallback.
|
||||
-- Agent: sidekick hosts my own agent CLI in a terminal split.
|
||||
local full = vim.g.profile == "full"
|
||||
local endpoint = vim.env.MINUET_ENDPOINT or "http://127.0.0.1:8012"
|
||||
local endpoint = vim.env.MINUET_ENDPOINT or "http://127.0.0.1:11434"
|
||||
|
||||
local function allowed(buf)
|
||||
buf = buf or vim.api.nvim_get_current_buf()
|
||||
@@ -44,17 +44,12 @@ return {
|
||||
},
|
||||
provider_options = {
|
||||
openai_fim_compatible = {
|
||||
name = "llama.cpp",
|
||||
api_key = "TERM", -- llama-server needs no key; any set env var works
|
||||
name = "ollama",
|
||||
api_key = "TERM", -- Ollama needs no key; any set env var works
|
||||
end_point = endpoint .. "/v1/completions",
|
||||
model = "qwen2.5-coder:3b",
|
||||
optional = { max_tokens = 56, top_p = 0.9 },
|
||||
template = {
|
||||
prompt = function(before, after, _)
|
||||
return "<|fim_prefix|>" .. before .. "<|fim_suffix|>" .. after .. "<|fim_middle|>"
|
||||
end,
|
||||
suffix = false,
|
||||
},
|
||||
-- default template: Ollama builds the FIM prompt itself from `prompt` + `suffix`
|
||||
},
|
||||
},
|
||||
},
|
||||
|
||||
@@ -5,10 +5,11 @@ local groups = {
|
||||
{ "<leader>b", group = "Buffers" },
|
||||
{ "<leader>q", group = "Session" },
|
||||
{ "<leader>u", group = "UI toggles" },
|
||||
{ "<leader>l", group = "LSP" },
|
||||
{ "gr", group = "LSP" },
|
||||
}
|
||||
if vim.g.profile == "full" then
|
||||
vim.list_extend(groups, {
|
||||
{ "<leader>l", group = "LSP" },
|
||||
{ "<leader>d", group = "Debug" },
|
||||
{ "<leader>a", group = "AI agent" },
|
||||
{ "<leader>c", group = "Code" },
|
||||
|
||||
Reference in new issue
Block a user