Updated 7. Example Custom Plugins (markdown)

Asep Komarudin 2024-06-12 17:43:52 +07:00
parent 772bfa8044
commit 194be91a03

@ -2775,4 +2775,47 @@ return {
require("telescope").load_extension "file_browser" require("telescope").load_extension "file_browser"
end, end,
} }
```
#Refactoring
```lua
return {
-- Incremental rename
{
"smjonas/inc-rename.nvim",
cmd = "IncRename",
keys = {
{
"<leader>un",
function()
return ":IncRename " .. vim.fn.expand "<cword>"
end,
desc = "Incremental rename",
mode = "n",
noremap = true,
expr = true,
},
},
config = true,
},
-- Refactoring tool
{
"ThePrimeagen/refactoring.nvim",
keys = {
{
"<leader>r",
function()
require("refactoring").select_refactor {
show_success_message = true,
}
end,
mode = "v",
noremap = true,
silent = true,
expr = false,
},
},
opts = {},
},
}
``` ```