summaryrefslogtreecommitdiff
path: root/lua/lv-galaxyline/init.lua
diff options
context:
space:
mode:
authortafryn <[email protected]>2021-05-25 16:09:32 -0700
committerGitHub <[email protected]>2021-05-25 19:09:32 -0400
commit3bdba45cc25523a32c8cd9b177827a6df3b2f800 (patch)
treeb61b8cf2b07e5b5e3cb7aa8b1e60134c9b4ec7b2 /lua/lv-galaxyline/init.lua
parent6f8f265e860dc298b7d7c8590410f55b89bd5f97 (diff)
Add treesitter indicator to status line (#429)
Diffstat (limited to 'lua/lv-galaxyline/init.lua')
-rw-r--r--lua/lv-galaxyline/init.lua24
1 files changed, 18 insertions, 6 deletions
diff --git a/lua/lv-galaxyline/init.lua b/lua/lv-galaxyline/init.lua
index 990ec407..b3509c5f 100644
--- a/lua/lv-galaxyline/init.lua
+++ b/lua/lv-galaxyline/init.lua
@@ -119,6 +119,18 @@ gls.right[3] = {
gls.right[4] = {DiagnosticInfo = {provider = 'DiagnosticInfo', icon = '  ', highlight = {colors.info_yellow, colors.bg}}}
gls.right[5] = {
+ TreesitterIcon = {
+ provider = function()
+ if next(vim.treesitter.highlighter.active) ~= nil then return ' ' end
+ return ''
+ end,
+ separator = ' ',
+ separator_highlight = {'NONE', colors.bg},
+ highlight = {colors.green, colors.bg}
+ }
+}
+
+gls.right[6] = {
ShowLspClient = {
provider = 'GetLspClient',
condition = function()
@@ -131,7 +143,7 @@ gls.right[5] = {
}
}
-gls.right[6] = {
+gls.right[7] = {
LineInfo = {
provider = 'LineColumn',
separator = ' ',
@@ -140,7 +152,7 @@ gls.right[6] = {
}
}
-gls.right[7] = {
+gls.right[8] = {
PerCent = {
provider = 'LinePercent',
separator = ' ',
@@ -149,7 +161,7 @@ gls.right[7] = {
}
}
-gls.right[8] = {
+gls.right[9] = {
Tabstop = {
provider = function()
return "Spaces: " .. vim.api.nvim_buf_get_option(0, "shiftwidth") .. " "
@@ -161,7 +173,7 @@ gls.right[8] = {
}
}
-gls.right[9] = {
+gls.right[10] = {
BufferType = {
provider = 'FileTypeName',
condition = condition.hide_in_width,
@@ -171,7 +183,7 @@ gls.right[9] = {
}
}
-gls.right[10] = {
+gls.right[11] = {
FileEncode = {
provider = 'FileEncode',
condition = condition.hide_in_width,
@@ -181,7 +193,7 @@ gls.right[10] = {
}
}
-gls.right[11] = {
+gls.right[12] = {
Space = {
provider = function()
return ' '