From 08345170081b5882535eaf32406a9c0e1b0a6f56 Mon Sep 17 00:00:00 2001 From: luetage Date: Thu, 9 Sep 2021 02:43:30 +0200 Subject: Show treesitter icon only with supported filetype (#1512) --- lua/core/lualine/components.lua | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'lua/core') diff --git a/lua/core/lualine/components.lua b/lua/core/lualine/components.lua index 5d240f46..c6800f49 100644 --- a/lua/core/lualine/components.lua +++ b/lua/core/lualine/components.lua @@ -71,7 +71,8 @@ return { }, treesitter = { function() - if next(vim.treesitter.highlighter.active) then + local b = vim.api.nvim_get_current_buf() + if next(vim.treesitter.highlighter.active[b]) then return "  " end return "" -- cgit v1.2.3