Feat(keymap): don't comment newline when using o key

Normal insert-mode newlines continue comments. Pressing `o` in normal-mode will create a newline
without commenting it.
This commit is contained in:
2025-03-05 15:24:38 -05:00
parent 1a5b574ef6
commit c6084225fd
+8 -1
View File
@@ -133,7 +133,6 @@ autocmd('CmdlineLeave', {
})
autogrp('RootyCustomEvent', { clear = true })
autocmd({ 'BufReadPost', 'BufNewFile' }, {
group = 'RootyCustomEvent',
callback = function(args)
@@ -145,3 +144,11 @@ autocmd({ 'BufReadPost', 'BufNewFile' }, {
end
end,
})
-- Don't comment next line when using `o`
vim.api.nvim_create_autocmd('FileType', {
pattern = '*',
callback = function()
vim.opt_local.formatoptions:remove({ 'o' })
end,
})