Initial commit

This commit is contained in:
Jiří Štefka 2024-03-06 02:24:31 +01:00 committed by GitHub
commit e2cff543d6
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
29 changed files with 2701 additions and 0 deletions
nvim/lua/user

23
nvim/lua/user/lsp.lua Normal file
View file

@ -0,0 +1,23 @@
---@mod user.lsp
---
---@brief [[
---LSP related functions
---@brief ]]
local M = {}
---Gets a 'ClientCapabilities' object, describing the LSP client capabilities
---Extends the object with capabilities provided by plugins.
---@return lsp.ClientCapabilities
function M.make_client_capabilities()
local capabilities = vim.lsp.protocol.make_client_capabilities()
-- Add com_nvim_lsp capabilities
local cmp_lsp = require('cmp_nvim_lsp')
local cmp_lsp_capabilities = cmp_lsp.default_capabilities()
capabilities = vim.tbl_deep_extend('keep', capabilities, cmp_lsp_capabilities)
-- Add any additional plugin capabilities here.
-- Make sure to follow the instructions provided in the plugin's docs.
return capabilities
end
return M