some fixes, switch back to fzf
This commit is contained in:
parent
021a4b7864
commit
08e9528be7
|
@ -5,24 +5,20 @@ local lspcap = require('cmp_nvim_lsp')
|
|||
.default_capabilities(vim.lsp.protocol.make_client_capabilities())
|
||||
local lspatt = function(client, bufnr)
|
||||
vim.api.nvim_buf_set_option(bufnr, 'omnifunc', 'v:lua.vim.lsp.omnifunc')
|
||||
-- disabling semantic highlighting for omnisharp https://github.com/OmniSharp/omnisharp-roslyn/issues/2483
|
||||
-- bug workaround for omnisharp https://github.com/OmniSharp/omnisharp-roslyn/issues/2483
|
||||
if client.name == "omnisharp" then
|
||||
local function toSnakeCase(str)
|
||||
return string.gsub(str, "%s*[- ]%s*", "_")
|
||||
end
|
||||
|
||||
local tokenModifiers = client.server_capabilities.semanticTokensProvider.legend.tokenModifiers
|
||||
for i, v in ipairs(tokenModifiers) do
|
||||
local tmp = string.gsub(v, ' ', '_')
|
||||
tokenModifiers[i] = string.gsub(tmp, '-_', '')
|
||||
tokenModifiers[i] = toSnakeCase(v)
|
||||
end
|
||||
local tokenTypes = client.server_capabilities.semanticTokensProvider.legend.tokenTypes
|
||||
for i, v in ipairs(tokenTypes) do
|
||||
local tmp = string.gsub(v, ' ', '_')
|
||||
tokenTypes[i] = string.gsub(tmp, '-_', '')
|
||||
tokenTypes[i] = toSnakeCase(v)
|
||||
end
|
||||
|
||||
--client.server_capabilities.semanticTokensProvider = {
|
||||
-- legend = {},
|
||||
-- vim_lsp_semantic_tokens = {},
|
||||
--}
|
||||
end
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in New Issue