summaryrefslogtreecommitdiff
path: root/.config/nvim
diff options
context:
space:
mode:
Diffstat (limited to '.config/nvim')
-rw-r--r--.config/nvim/plugins/indent_blankline.vim48
1 files changed, 40 insertions, 8 deletions
diff --git a/.config/nvim/plugins/indent_blankline.vim b/.config/nvim/plugins/indent_blankline.vim
index 227ac86..2702b4f 100644
--- a/.config/nvim/plugins/indent_blankline.vim
+++ b/.config/nvim/plugins/indent_blankline.vim
@@ -1,11 +1,43 @@
lua <<EOF
-vim.api.nvim_set_hl(0, 'IndentBlanklineChar', { fg = '#303030', nocombine = true })
-vim.api.nvim_set_hl(0, 'IndentBlanklineContextChar', { fg = '#404040', nocombine = true })
-
-require('indent_blankline').setup {
- use_treesitter = true,
- show_first_indent_level = false,
- show_trailing_blankline_indent = false,
- show_current_context = true,
+
+local hooks = require('ibl.hooks')
+
+hooks.register(
+ hooks.type.WHITESPACE,
+ hooks.builtin.hide_first_space_indent_level
+)
+
+hooks.register(
+ hooks.type.WHITESPACE,
+ hooks.builtin.hide_first_tab_indent_level
+)
+
+hooks.register(
+ hooks.type.HIGHLIGHT_SETUP,
+ function()
+ vim.api.nvim_set_hl(0, 'IndentBlanklineChar', { fg = '#303030', nocombine = true })
+ vim.api.nvim_set_hl(0, 'IndentBlanklineContextChar', { fg = '#404040', nocombine = true })
+ end
+)
+
+
+require('ibl').setup {
+ indent = {
+ highlight = {
+ 'IndentBlanklineChar',
+ },
+ },
+
+ whitespace = {
+ remove_blankline_trail = true,
+ },
+
+ scope = {
+ enabled = false,
+
+ highlight = {
+ 'IndentBlanklineContextChar',
+ },
+ },
}
EOF