summaryrefslogtreecommitdiff
path: root/lua
diff options
context:
space:
mode:
Diffstat (limited to 'lua')
-rw-r--r--lua/plugins.lua28
-rw-r--r--lua/style.lua43
2 files changed, 64 insertions, 7 deletions
diff --git a/lua/plugins.lua b/lua/plugins.lua
index 4fb084e..35e8e72 100644
--- a/lua/plugins.lua
+++ b/lua/plugins.lua
@@ -55,9 +55,6 @@ require("lazy").setup({
"lukas-reineke/indent-blankline.nvim",
main = "ibl",
tag = "v3.5.3",
- opts = {
- indent = { char = '¦' }
- }
},
-- Style end
-- Telescope
@@ -118,7 +115,7 @@ require("lazy").setup({
}
},
-- Telescope end
- -- Syntax & formatting
+ -- Syntax highlighting & formatting
{
"tikhomirov/vim-glsl",
commit = "bfd330a271933c3372fcfa8ce052970746c8e9dd"
@@ -129,8 +126,27 @@ require("lazy").setup({
},
{
"nvim-treesitter/nvim-treesitter",
- tag = "v0.9.2";
- build = ":TSUpdate"
+ commit = "1c111e3e8f42c85b16cb4bf30e4254fcb5607817";
+ build = ":TSUpdate",
+ config = function ()
+ local configs = require("nvim-treesitter.configs")
+
+ configs.setup({
+ ensure_installed = {
+ "c", "lua", "vim", "vimdoc", "rust", "python", "javascript",
+ "html", "cpp"
+ },
+ sync_install = false,
+ highlight = {
+ enable = true,
+ },
+ indent = { enable = true },
+ })
+ end
+ },
+ {
+ "https://gitlab.com/HiPhish/rainbow-delimiters.nvim",
+ commit = "d227e6c9879bb50af35cd733461198666981d482" -- 0.6.2
},
-- Syntax & formatting end
-- Markdown
diff --git a/lua/style.lua b/lua/style.lua
index 5ffc70b..365ea9a 100644
--- a/lua/style.lua
+++ b/lua/style.lua
@@ -1,6 +1,14 @@
+vim.o.background = "dark"
+
local ayu_colors = require('ayu.colors')
-ayu_colors.generate() -- Pass `true` to enable mirage
+ayu_colors.generate()
+
+ayu_colors.entity = "#3EB8FF"
+ayu_colors.tag = ayu_colors.fg
+
+-- The colors should not be regenerated
+require("ayu.colors").generate = function() end
require('ayu').setup({
overrides = {
@@ -65,3 +73,36 @@ bufferline.setup {
}
}
}
+
+local highlight = {
+ "RainbowRed",
+ "RainbowYellow",
+ "RainbowBlue",
+ "RainbowOrange",
+ "RainbowGreen",
+ "RainbowViolet",
+ "RainbowCyan",
+}
+
+local hooks = require "ibl.hooks"
+
+-- create the highlight groups in the highlight setup hook, so they are reset
+-- every time the colorscheme changes
+hooks.register(hooks.type.HIGHLIGHT_SETUP, function()
+ vim.api.nvim_set_hl(0, "RainbowRed", { fg = "#E06C75" })
+ vim.api.nvim_set_hl(0, "RainbowYellow", { fg = "#E5C07B" })
+ vim.api.nvim_set_hl(0, "RainbowBlue", { fg = "#61AFEF" })
+ vim.api.nvim_set_hl(0, "RainbowOrange", { fg = "#D19A66" })
+ vim.api.nvim_set_hl(0, "RainbowGreen", { fg = "#98C379" })
+ vim.api.nvim_set_hl(0, "RainbowViolet", { fg = "#C678DD" })
+ vim.api.nvim_set_hl(0, "RainbowCyan", { fg = "#56B6C2" })
+end)
+
+vim.g.rainbow_delimiters = { highlight = highlight }
+
+require("ibl").setup {
+ indent = { char = '¦' },
+ scope = { highlight = highlight, show_start = false, show_exact_scope = false }
+}
+
+hooks.register(hooks.type.SCOPE_HIGHLIGHT, hooks.builtin.scope_highlight_from_extmark)