format lines <leader>fl

This commit is contained in:
Christoph J. Scherr 2024-07-06 02:06:24 +02:00
parent ec84dfc857
commit 5dd7b23adf
1 changed files with 3 additions and 0 deletions

View File

@ -101,6 +101,9 @@ vim.keymap.set({ 'n', 'v' }, '<Down>', '<cmd> move+2<cr>', { desc = 'Move line d
vim.keymap.set({ 'n', 'v' }, '<Left>', '<<', { desc = 'Less indentation' })
vim.keymap.set({ 'n', 'v' }, '<Right>', '>>', { desc = 'More indentation' })
-- format a long line into multiple with length 80
vim.keymap.set({ 'v' }, '<leader>fl', ':!fmt -w80<CR>', { desc = '[F]ormat long [L]ines into smaller ones' })
--------------------------------------------------------------------------------
-- Formating
--------------------------------------------------------------------------------