dotfiles/dot_config/nvim/lua/config/autocmds.lua

24 lines
705 B
Lua
Raw Normal View History

2023-10-13 21:54:13 +02:00
-- Autocmds are automatically loaded on the VeryLazy event
-- Default autocmds that are always set: https://github.com/LazyVim/LazyVim/blob/main/lua/lazyvim/config/autocmds.lua
-- Add any additional autocmds here
vim.api.nvim_create_autocmd("FileType", {
pattern = { "norg" },
callback = function()
vim.opt_local.wrap = true
vim.opt_local.spell = true
end,
})
2024-01-22 17:26:01 +01:00
vim.api.nvim_create_autocmd("FileType", {
pattern = { "markdown" },
callback = function()
vim.opt_local.textwidth = 80
vim.opt_local.wrap = true
vim.opt_local.spell = true
vim.opt_local.tabstop = 2
vim.opt_local.softtabstop = 2
vim.opt_local.shiftwidth = 2
vim.opt_local.expandtab = true
end,
})