Cleanup nvim-cmp config callback
This commit is contained in:
parent
fcd5cfbd54
commit
6affd78df7
@ -180,11 +180,12 @@ return {
|
|||||||
vim.api.nvim_create_autocmd('LspAttach', {
|
vim.api.nvim_create_autocmd('LspAttach', {
|
||||||
pattern = '*',
|
pattern = '*',
|
||||||
group = augroup,
|
group = augroup,
|
||||||
callback = function(ev)
|
callback = function(event)
|
||||||
local opts = { noremap = true, buffer = ev.buf }
|
local opts = { noremap = true, buffer = event.buf }
|
||||||
|
|
||||||
-- Fixit mapping, or close enough, actually any code action
|
-- Fixit mapping, or close enough, actually any code action
|
||||||
vim.keymap.set('n', '<leader>fi', require('actions-preview').code_actions, opts)
|
vim.keymap.set('n', '<leader>fi',
|
||||||
|
require('actions-preview').code_actions, opts)
|
||||||
|
|
||||||
-- Goto mappings
|
-- Goto mappings
|
||||||
local tb = require('telescope.builtin')
|
local tb = require('telescope.builtin')
|
||||||
@ -212,7 +213,8 @@ return {
|
|||||||
|
|
||||||
-- Swtich file using clangd extension
|
-- Swtich file using clangd extension
|
||||||
-- TODO: limit this to only filetypes supported by clangd
|
-- TODO: limit this to only filetypes supported by clangd
|
||||||
vim.keymap.set('n', '<leader>sf', ':ClangdSwitchSourceHeader<CR>', { silent = true })
|
vim.keymap.set('n', '<leader>sf',
|
||||||
|
':ClangdSwitchSourceHeader<CR>', { silent = true })
|
||||||
end
|
end
|
||||||
})
|
})
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user