nvim: add quarto-nvim
This commit is contained in:
parent
5612d97dc4
commit
9720cf47f7
2 changed files with 79 additions and 44 deletions
|
@ -141,10 +141,12 @@ M.cmp = function()
|
|||
sources = {
|
||||
{ name = 'nvim_lsp' },
|
||||
{ name = 'nvim_lua' },
|
||||
{ name = 'otter' },
|
||||
{ name = 'pandoc_references' },
|
||||
{ name = 'luasnip' },
|
||||
{ name = 'treesitter' },
|
||||
{ name = 'calc' },
|
||||
-- { name = 'spell' },
|
||||
{ name = 'spell' },
|
||||
{ name = 'emoji' },
|
||||
{ name = 'buffer' },
|
||||
{ name = 'path' },
|
||||
|
@ -158,16 +160,18 @@ M.cmp = function()
|
|||
-- set a name for each source
|
||||
vim_item.kind = " " .. kind.kind
|
||||
vim_item.menu = ({
|
||||
path = "[path]",
|
||||
emoji = "[emoji]",
|
||||
nvim_lua = "[lua]",
|
||||
nvim_lsp = "[lsp]",
|
||||
treesitter = "[ts]",
|
||||
calc = "[calc]",
|
||||
spell = "[spell]",
|
||||
cmdline = "[cmd]",
|
||||
buffer = "[buf]",
|
||||
luasnip = "[snip]",
|
||||
path = "[path]",
|
||||
emoji = "[emoji]",
|
||||
nvim_lua = "[lua]",
|
||||
nvim_lsp = "[lsp]",
|
||||
treesitter = "[ts]",
|
||||
calc = "[calc]",
|
||||
spell = "[spell]",
|
||||
cmdline = "[cmd]",
|
||||
buffer = "[buf]",
|
||||
luasnip = "[snip]",
|
||||
pandoc_references = "[pandoc]",
|
||||
otter = "[quarto]",
|
||||
})[entry.source.name] or "unknown type"
|
||||
return vim_item
|
||||
end,
|
||||
|
@ -182,7 +186,7 @@ M.cmp = function()
|
|||
},
|
||||
experimental = {
|
||||
ghost_text = true,
|
||||
}
|
||||
},
|
||||
}
|
||||
-- Thanks to iwataka on github for this bit
|
||||
local search_config = {
|
||||
|
@ -256,18 +260,19 @@ M.lspconfig = function()
|
|||
-- Use a loop to conveniently call 'setup' on multiple servers and
|
||||
-- map buffer local keybindings when the language server attaches
|
||||
local lsp_servers = {
|
||||
-- 'lsp_name',
|
||||
'clangd',
|
||||
'bashls',
|
||||
'rust_analyzer',
|
||||
'dockerls',
|
||||
-- 'yamlls',
|
||||
'html',
|
||||
'clangd',
|
||||
'cssls',
|
||||
'dockerls',
|
||||
'eslint',
|
||||
'html',
|
||||
'jsonls',
|
||||
'kotlin_language_server',
|
||||
'marksman',
|
||||
'nil_ls',
|
||||
'nil_ls',
|
||||
'rust_analyzer',
|
||||
'yamlls',
|
||||
}
|
||||
for _, lsp in pairs(lsp_servers) do
|
||||
nvim_lsp[lsp].setup {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue