feat(autocmds): Split config for autocmds

This commit is contained in:
Xavier Logerais
2023-11-02 18:29:29 +01:00
parent 0bde02eab6
commit 095d08c050
4 changed files with 47 additions and 7 deletions

View File

@ -0,0 +1,9 @@
vim.api.nvim_create_autocmd("FileType", {
desc = "Enable wrap and spell for text like documents",
group = vim.api.nvim_create_augroup("auto_spell", { clear = true }),
pattern = { "gitcommit", "markdown", "text", "plaintex" },
callback = function()
vim.opt_local.wrap = true
vim.opt_local.spell = true
end,
})