Manage folds

This commit is contained in:
Fabrice Mouhartem 2023-12-24 19:17:20 +01:00
parent ef8f52e152
commit d377f3432a
2 changed files with 8 additions and 0 deletions

View File

@ -49,6 +49,8 @@ for _,o in ipairs(set_true) do
vim.o[o] = true
end
-- folds
vim.g.ip_skipfold=true
-- window management
vim.o.tw = 80

View File

@ -30,3 +30,9 @@ vim.api.nvim_set_keymap("n", "<Leader>y", '"+y', {noremap = true, silent = true}
vim.api.nvim_set_keymap("v", "<Leader>y", '"+y', {noremap = true, silent = true})
vim.api.nvim_set_keymap("n", "<Leader>pp", '"+p', {noremap = true, silent = true})
vim.api.nvim_set_keymap("v", "<Leader>pp", '"+p', {noremap = true, silent = true})
-- z0…z9 to open folds to a certain level
for i=0,9 do
vim.api.nvim_set_keymap('n', 'z' .. i , ':set fdl=' .. i .. '<CR>', {noremap = true, silent = false})
end