This commit is contained in:
Belal Elsabbagh
2025-11-14 14:11:43 +02:00
parent 030ceba87c
commit 1a8e43f949
4 changed files with 37 additions and 15 deletions

View File

@@ -96,16 +96,6 @@ vim.api.nvim_create_autocmd('LspAttach', {
vim.keymap.set(mode, keys, func, { buffer = event.buf, desc = 'LSP: ' .. desc })
end
map('gd', require('telescope.builtin').lsp_definitions, '[G]oto [D]efinition')
map('gr', require('telescope.builtin').lsp_references, '[G]oto [R]eferences')
map('gI', require('telescope.builtin').lsp_implementations, '[G]oto [I]mplementation')
map('<leader>D', require('telescope.builtin').lsp_type_definitions, 'Type [D]efinition')
map('<leader>ds', require('telescope.builtin').lsp_document_symbols, '[D]ocument [S]ymbols')
map('<leader>ws', require('telescope.builtin').lsp_dynamic_workspace_symbols, '[W]orkspace [S]ymbols')
map('<leader>rn', vim.lsp.buf.rename, '[R]e[n]ame')
map('<leader>ca', vim.lsp.buf.code_action, '[C]ode [A]ction', { 'n', 'x' })
map('gD', vim.lsp.buf.declaration, '[G]oto [D]eclaration')
local client = vim.lsp.get_client_by_id(event.data.client_id)
if client and client.supports_method(vim.lsp.protocol.Methods.textDocument_documentHighlight) then
local highlight_augroup = vim.api.nvim_create_augroup('kickstart-lsp-highlight', { clear = false })
@@ -151,4 +141,5 @@ vim.lsp.enable {
'tsls',
'yamlls',
'astrols',
'bashls',
}

View File

@@ -32,7 +32,7 @@ return {
json = { 'biome', 'prettier', stop_after_first = true },
vue = { 'biome', 'prettier' },
svelte = { 'biome', 'prettier', stop_after_first = true },
php = { 'pint', 'intelephense', stop_after_first = true },
php = { 'pint', stop_after_first = true },
},
formatters = {
biome = {
@@ -71,10 +71,6 @@ return {
end,
stdin = true,
},
intelephense = {
command = 'intelephense',
args = {},
},
},
},
}

View File

@@ -0,0 +1,31 @@
return {
{
'folke/lazydev.nvim',
ft = 'lua', -- only load on lua files
opts = {
library = {
-- See the configuration section for more details
-- Load luvit types when the `vim.uv` word is found
{ path = '${3rd}/luv/library', words = { 'vim%.uv' } },
},
},
},
{ -- optional blink completion source for require statements and module annotations
'saghen/blink.cmp',
opts = {
sources = {
-- add lazydev to your completion providers
default = { 'lazydev', 'lsp', 'path', 'snippets', 'buffer' },
providers = {
lazydev = {
name = 'LazyDev',
module = 'lazydev.integrations.blink',
-- make lazydev completions top priority (see `:h blink.cmp`)
score_offset = 100,
},
},
},
},
},
-- { "folke/neodev.nvim", enabled = false }, -- make sure to uninstall or disable neodev.nvim
}