Skip to content

Commit

Permalink
refactor(indent): simplify indent-blankline with rainbow-delimiters i…
Browse files Browse the repository at this point in the history
…mplementation
  • Loading branch information
mehalter committed Apr 22, 2024
1 parent 39ab80d commit 14c5156
Show file tree
Hide file tree
Showing 5 changed files with 39 additions and 89 deletions.
Binary file not shown.
27 changes: 0 additions & 27 deletions lua/astrocommunity/indent/bracket-pair-colorizer/README.md

This file was deleted.

62 changes: 0 additions & 62 deletions lua/astrocommunity/indent/bracket-pair-colorizer/init.lua

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# rainbow-delimiters.nvim integration for indent-blankline.nvim

Provides rainbow indent guides that tie into their relevant bracket pairs, and a scope guide
Provides `rainbow-delimiters.nvim` and configures `indent-blankline.nvim` as described in the [indent-blankline.nvim documentation](https://github.com/lukas-reineke/indent-blankline.nvim/tree/master?tab=readme-ov-file#rainbow-delimitersnvim-integration)

**Repository:** <https://github.com/lukas-reineke/indent-blankline.nvim>
**Repository:** <https://gitlab.com/HiPhish/rainbow-delimiters.nvim>

## Preview

![indent-colorizer-preview](https://github.com/lukas-reineke/indent-blankline.nvim/assets/12900252/67707d8e-57d3-411c-8418-77908d8babd9)
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
return {
{ import = "astrocommunity.editing-support.rainbow-delimiters-nvim" },
{
"lukas-reineke/indent-blankline.nvim",
main = "ibl",
dependencies = { "HiPhish/rainbow-delimiters.nvim" },
opts = function(_, opts)
if not opts.scope then opts.scope = {} end
opts.scope.highlight = vim.g.rainbow_delimiters.highlight
or {
"RainbowDelimiterRed",
"RainbowDelimiterYellow",
"RainbowDelimiterBlue",
"RainbowDelimiterOrange",
"RainbowDelimiterGreen",
"RainbowDelimiterViolet",
"RainbowDelimiterCyan",
}
end,

config = function(plugin, opts)
require(plugin.main).setup(opts)

local hooks = require "ibl.hooks"
hooks.register(hooks.type.SCOPE_HIGHLIGHT, hooks.builtin.scope_highlight_from_extmark)
end,
},
}

0 comments on commit 14c5156

Please sign in to comment.