mirror of
https://github.com/kogakure/dotfiles.git
synced 2026-02-03 20:25:30 +00:00
feat: add keymap for sorting by indentation
This commit is contained in:
@@ -89,3 +89,5 @@ vim.keymap.set("n", "<leader>P", "<cmd>Prettier<CR>", { desc = "Format with Pret
|
||||
vim.keymap.set("n", "<leader>kn", ":let @+=@%<CR>", { desc = "Get the filename and path of current file", noremap = true, silent = true })
|
||||
vim.keymap.set("n", "<leader>kc", ":g/console.log/d<CR>", { desc = "Remove console.log statements", noremap = true, silent = true })
|
||||
vim.keymap.set("v", "<leader>kp", ":'<,'> w !pandoc --no-highlight --wrap=none | pbcopy <CR>", { desc = "Convert Markdown to HTML and copy to Clipboard", noremap = true, silent = true })
|
||||
|
||||
vim.keymap.set("n", "gsii", "<CMD>lua Select_indent()<CR>:sort<CR>", { desc = "Sort lines by indentation", noremap = true, silent = true })
|
||||
|
||||
@@ -63,13 +63,13 @@ end
|
||||
-- Indent Text Object
|
||||
function Indent_text_objects()
|
||||
for _, mode in ipairs({ "x", "o" }) do
|
||||
keymap(mode, "ii", ":<c-u>lua select_indent()<cr>", {
|
||||
keymap(mode, "ii", ":<c-u>lua Select_indent()<cr>", {
|
||||
noremap = true,
|
||||
silent = true,
|
||||
})
|
||||
keymap(mode, "ai", ":<c-u>lua select_indent(true)<cr>", {
|
||||
noremap = true,
|
||||
keymap(mode, "ai", ":<c-u>lua Select_indent(true)<cr>", {
|
||||
silent = true,
|
||||
noremap = true,
|
||||
})
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user