From 8ee3b57e3a6199b0109407110ea5ff1dee45fce6 Mon Sep 17 00:00:00 2001 From: Jeremy Kaplan Date: Mon, 11 Aug 2025 11:12:47 -0400 Subject: [PATCH] neovim: Configure illuminate --- neovim/lua/jdkaplan/cool_theme.lua | 5 +++++ neovim/lua/jdkaplan/warm_theme.lua | 5 +++++ neovim/lua/plugins/ide.lua | 11 ++++++++++- 3 files changed, 20 insertions(+), 1 deletion(-) diff --git a/neovim/lua/jdkaplan/cool_theme.lua b/neovim/lua/jdkaplan/cool_theme.lua index a28ac9b..64f15af 100644 --- a/neovim/lua/jdkaplan/cool_theme.lua +++ b/neovim/lua/jdkaplan/cool_theme.lua @@ -145,6 +145,11 @@ local theme = lush(function(injected_functions) -- lukas-reineke/indent-blankline.nvim IblIndent { fg = "#000000" }, + -- RRethy/vim-illuminate + IlluminatedWordText { bold = true }, + IlluminatedWordRead { IlluminatedWordText }, + IlluminatedWordWrite { IlluminatedWordText, underline = true }, + -- For :Lushify to work, the groups have to be spelled as `sym` called -- on a string literal. diff --git a/neovim/lua/jdkaplan/warm_theme.lua b/neovim/lua/jdkaplan/warm_theme.lua index b612d01..fc155ed 100644 --- a/neovim/lua/jdkaplan/warm_theme.lua +++ b/neovim/lua/jdkaplan/warm_theme.lua @@ -145,6 +145,11 @@ local theme = lush(function(injected_functions) -- lukas-reineke/indent-blankline.nvim IblIndent { fg = "#eeeeee" }, + -- RRethy/vim-illuminate + IlluminatedWordText { bold = true }, + IlluminatedWordRead { IlluminatedWordText }, + IlluminatedWordWrite { IlluminatedWordText, underline = true }, + -- For :Lushify to work, the groups have to be spelled as `sym` called -- on a string literal. diff --git a/neovim/lua/plugins/ide.lua b/neovim/lua/plugins/ide.lua index f99a549..83e6e12 100644 --- a/neovim/lua/plugins/ide.lua +++ b/neovim/lua/plugins/ide.lua @@ -64,8 +64,17 @@ return { }, { "RRethy/vim-illuminate", + init = function() + local illuminate = require('illuminate') + illuminate.configure({ + delay = 500, + }) + end, keys = { - { "i", ":IlluminateToggle" }, + { "ii", function() require('illuminate').toggle_buf() end }, + { "in", function() require('illuminate').goto_next_reference() end }, + { "ip", function() require('illuminate').goto_prev_reference() end }, + { "if", function() require('illuminate').toggle_freeze_buf() end }, }, }, {