diff options
-rw-r--r-- | nvim/nvim/init.lua | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/nvim/nvim/init.lua b/nvim/nvim/init.lua index 1145a29..1193861 100644 --- a/nvim/nvim/init.lua +++ b/nvim/nvim/init.lua @@ -37,10 +37,7 @@ vim.cmd.colorscheme("dracula") vim.opt.cursorline = true vim.cmd.highlight("CursorColumn", "ctermbg=DarkGrey", "guibg=#262626") vim.cmd.highlight("CursorLine", "ctermbg=DarkGrey", "guibg=#262626") - -vim.opt.colorcolumn = "80" vim.cmd.highlight("ColorColumn", "ctermbg=DarkGrey", "guibg=#262626") - vim.cmd.highlight("ExtraWhitespace", "ctermbg=red", "guibg=red") -- HighLight search @@ -113,6 +110,14 @@ vim.opt.shiftwidth=4 -- Formatting vim.opt.textwidth=79 vim.opt.formatoptions="jcroql" +-- Put colorcolumn after editorconfig is loaded +vim.api.nvim_create_autocmd({ "BufEnter" }, { + pattern = { "*" }, + callback = function() + vim.opt.colorcolumn=tostring(vim.o.textwidth+1) + end, +}) + require'nvim-treesitter.configs'.setup { -- A list of parser names, or "all" |