summaryrefslogtreecommitdiff
path: root/init.lua
diff options
context:
space:
mode:
Diffstat (limited to 'init.lua')
-rw-r--r--init.lua4
1 files changed, 3 insertions, 1 deletions
diff --git a/init.lua b/init.lua
index 6c6ae02..c7e6400 100644
--- a/init.lua
+++ b/init.lua
@@ -514,7 +514,9 @@ local on_attach = function(_, bufnr)
end
nmap('<leader>rn', vim.lsp.buf.rename, '[R]e[n]ame')
- nmap('<leader>ca', vim.lsp.buf.code_action, '[C]ode [A]ction')
+ nmap('<leader>ca', function()
+ vim.lsp.buf.code_action { context = { only = { 'quickfix', 'refactor', 'source' } } }
+ end, '[C]ode [A]ction')
nmap('gd', require('telescope.builtin').lsp_definitions, '[G]oto [D]efinition')
nmap('gr', require('telescope.builtin').lsp_references, '[G]oto [R]eferences')