aboutsummaryrefslogtreecommitdiff
path: root/runtime/lua/vim/_defaults.lua
diff options
context:
space:
mode:
authorGregory Anders <8965202+gpanders@users.noreply.github.com>2024-05-06 08:13:50 -0500
committerGitHub <noreply@github.com>2024-05-06 08:13:50 -0500
commitbb032d952bfc692062fceb764ff2742c5bdd3324 (patch)
tree8623d93146cddf7fb4c785ecf0eb2aa017c4aa65 /runtime/lua/vim/_defaults.lua
parent783c1e596c35e44e9699e5a1881d3c8f5c4fc596 (diff)
downloadrneovim-bb032d952bfc692062fceb764ff2742c5bdd3324.tar.gz
rneovim-bb032d952bfc692062fceb764ff2742c5bdd3324.tar.bz2
rneovim-bb032d952bfc692062fceb764ff2742c5bdd3324.zip
revert: default LSP mappings (#28649)
Revert the default LSP mappings before the 0.10 release as these might need some further consideration. In particular, it's not clear if "c" prefixed maps in Normal mode are acceptable as defaults since they interfere with text objects or operator ranges. We will re-introduce default mappings at the beginning of the 0.11 release cycle, this reversion is only for the imminent 0.10 release.
Diffstat (limited to 'runtime/lua/vim/_defaults.lua')
-rw-r--r--runtime/lua/vim/_defaults.lua30
1 files changed, 0 insertions, 30 deletions
diff --git a/runtime/lua/vim/_defaults.lua b/runtime/lua/vim/_defaults.lua
index bd1afd0beb..4684902410 100644
--- a/runtime/lua/vim/_defaults.lua
+++ b/runtime/lua/vim/_defaults.lua
@@ -146,36 +146,6 @@ do
vim.keymap.set({ 'o' }, 'gc', textobject_rhs, { desc = 'Comment textobject' })
end
- --- Default maps for LSP functions.
- ---
- --- These are mapped unconditionally to avoid confusion. If no server is attached, or if a server
- --- does not support a capability, an error message is displayed rather than exhibiting different
- --- behavior.
- ---
- --- See |gr-default|, |crn|, |crr|, |i_CTRL-S|.
- do
- vim.keymap.set('n', 'crn', function()
- vim.lsp.buf.rename()
- end, { desc = 'vim.lsp.buf.rename()' })
-
- local function map_codeaction(mode, lhs)
- vim.keymap.set(mode, lhs, function()
- vim.lsp.buf.code_action()
- end, { desc = 'vim.lsp.buf.code_action()' })
- end
- map_codeaction('n', 'crr')
- map_codeaction('x', '<C-R>r')
- map_codeaction('x', '<C-R><C-R>')
-
- vim.keymap.set('n', 'gr', function()
- vim.lsp.buf.references()
- end, { desc = 'vim.lsp.buf.references()' })
-
- vim.keymap.set('i', '<C-S>', function()
- vim.lsp.buf.signature_help()
- end, { desc = 'vim.lsp.buf.signature_help()' })
- end
-
--- Map [d and ]d to move to the previous/next diagnostic. Map <C-W>d to open a floating window
--- for the diagnostic under the cursor.
---