trailing whitespace
This commit is contained in:
parent
383f7fe4be
commit
d9cdc25e2f
|
@ -284,22 +284,30 @@ M.edit = {
|
|||
-- split and join lines
|
||||
-- "J" for join is defaul
|
||||
["S"] = {
|
||||
"i<CR>k<END><ESC>",
|
||||
"i<CR><ESC>l",
|
||||
"split line",
|
||||
},
|
||||
|
||||
-- do something useful with the arrows
|
||||
["<Up>"] = { "<cmd> move-2<CR>", "Move line up", opts = { expr = true } },
|
||||
["<Down>"] = { "<cmd> move+<CR>", "Move line down", opts = { expr = true } },
|
||||
["<LEFT>"] = { "<<", "Less indentation", opts = { expr = true } },
|
||||
["<RIGHT>"] = { ">>", "More indentation", opts = { expr = true } },
|
||||
["<LEFT>"] = { "<cmd> << <CR>", "Less indentation", opts = { expr = true } },
|
||||
["<RIGHT>"] = { "<cmd> >> <CR>", "More indentation", opts = { expr = true } },
|
||||
|
||||
-- format with conform
|
||||
["<leader>ff"] = {
|
||||
function()
|
||||
require("conform").format()
|
||||
end,
|
||||
"formatting",
|
||||
"format buffer",
|
||||
},
|
||||
--
|
||||
-- remove trailing whitespace
|
||||
["<leader>fw"] = {
|
||||
function()
|
||||
require('mini.trailspace').trim()
|
||||
end,
|
||||
"remove whitespace",
|
||||
},
|
||||
},
|
||||
v = {
|
||||
|
|
|
@ -85,6 +85,7 @@ local plugins = {
|
|||
"folke/which-key.nvim",
|
||||
keys = { "<leader>", "<localleader>", "<c-r>", "<c-w>", '"', "'", "`", "c", "v", "g" },
|
||||
},
|
||||
{ "echasnovski/mini.trailspace", lazy = false, event = { "BufReadPost", "BufNewFile" }, opts = {} },
|
||||
}
|
||||
|
||||
return plugins
|
||||
|
|
Loading…
Reference in New Issue