diff --git a/lua/config/opts.lua b/lua/config/opts.lua index 9182d1f..f819e93 100644 --- a/lua/config/opts.lua +++ b/lua/config/opts.lua @@ -31,6 +31,27 @@ opt.wrap = false opt.smoothscroll = true opt.swapfile = false -- disable swapfiles because they are fucking garbage opt.smartindent = true +opt.confirm = true +opt.number = true +opt.foldcolumn = "1" +opt.foldlevel = 99 +opt.foldlevelstart = 99 +opt.foldenable = true +opt.fillchars = { + foldopen = "", + foldclose = "", + fold = " ", + foldsep = " ", + diff = "╱", + eob = " ", + horiz = "─", + horizup = "─", + horizdown = "─", + vert = "▎", + vertleft = "▎", + vertright = "▎", + verthoriz = "▎", +} -- -- VIM global options diff --git a/lua/plugins/nvim-ufo.lua b/lua/plugins/nvim-ufo.lua new file mode 100644 index 0000000..5b9b52d --- /dev/null +++ b/lua/plugins/nvim-ufo.lua @@ -0,0 +1,29 @@ +-- +-- High performance and modern folds. +-- +-- Source: https://github.com/kevinhwang91/nvim-ufo +-- .............................................. +-- +-- Author: Sven Vogel +-- Created: 20.11.2024 +-- Edited: 20.11.2024 +-- +-- ============================================== + +return { + { + "kevinhwang91/nvim-ufo", + event = { + "LspAttach", + }, + dependencies = { + "kevinhwang91/promise-async", + }, + opts = { + -- register treesitter as source for scopes + provider_selector = function(_, _, _) + return { "treesitter", "indent" } + end + } + } +} diff --git a/lua/plugins/statuscol.lua b/lua/plugins/statuscol.lua new file mode 100644 index 0000000..4db6302 --- /dev/null +++ b/lua/plugins/statuscol.lua @@ -0,0 +1,58 @@ +-- +-- Status column with click handlers +-- +-- Source: https://github.com/luukvbaal/statuscol.nvim +-- .............................................. +-- +-- Author: Sven Vogel +-- Created: 07.11.2024 +-- Edited: 07.11.2024 +-- +-- ============================================== + +return { + { + 'luukvbaal/statuscol.nvim', + lazy = true, + event = { + "BufEnter", + "LspAttach" + }, + config = function() + local builtin = require("statuscol.builtin") + require("statuscol").setup({ + setopt = true, + ft_ignore = { + "neo-tree" + }, + segments = { + -- diagnostic signs + { + sign = { + name = { "Diagnostic" }, + colwidth = 2, + maxwidth = 1, + condition = { true } + }, + click = "v:lua.ScSa" + }, + -- line numbers + { + text = { builtin.lnumfunc, " " }, + click = "v:lua.ScLa", + }, + -- folds + { + text = { builtin.foldfunc }, + click = "v:lua.ScFa" + }, + -- git signs + { + sign = { namespace = { "gitsigns" } }, + click = "v:lua.ScSa" + } + } + }) + end + } +}