summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--.vim/lua/plugins.lua41
1 files changed, 9 insertions, 32 deletions
diff --git a/.vim/lua/plugins.lua b/.vim/lua/plugins.lua
index 2a262f3..dbd94f4 100644
--- a/.vim/lua/plugins.lua
+++ b/.vim/lua/plugins.lua
@@ -354,39 +354,16 @@ return require('packer').startup({function()
   use {'kosayoda/nvim-lightbulb', -- {{{
     -- branch = 'virtual-text-column',
     config = function()
-      _G.lightbulb_config = {
-        sign = {
-          enabled = false,
-          priority = 10,
-        },
-        float = {
-          enabled = false,
-          text = '󰌵',
-          win_opts = {},
-        },
-        virtual_text = {
-          enabled = false,
-          text = '← 󰌵',
-          text_pos = 'eol',
-          column = -1,
-        },
-        -- status text only works on master
-        status_text = {
-          enabled = true,
-          text = '󰌵',
-          test_unavailable = '',
-        }
+      require('nvim-lightbulb').setup {
+        ignore = {'null-ls'},
+        sign         = { enabled = false },
+        virtual_text = { enabled = false, text = '←  󰌵' },
+        status_text  = { enabled = true, text = '󰌵', text_unavailable = '' }
       }
-
-      -- vim.fn.sign_define({{name='LightBulbSign', text='󰌵', texthl='LightBulbVirtualText'}})
-
-      local group = vim.api.nvim_create_augroup('LightBulbUpdate', { clear = true })
-      vim.api.nvim_create_autocmd('CursorHold', {
-        pattern = '*',
-        callback = function()
-          require('nvim-lightbulb').update_lightbulb(_G.lightbulb_config)
-        end,
-        group = group,
+      vim.fn.sign_define({{name='LightBulbSign', text='󰌵', texthl='LightBulbSign'}})
+      vim.api.nvim_create_autocmd({'CursorHold', 'CursorHoldI'}, {
+        callback = require('nvim-lightbulb').update_lightbulb,
+        group = vim.api.nvim_create_augroup('LightBulbUpdate', {}),
       })
     end} -- }}}