2021-03-12 20:23:02 -05:00
|
|
|
|
local gl = require("galaxyline")
|
2021-03-07 09:22:30 -05:00
|
|
|
|
local gls = gl.section
|
2021-04-02 01:36:20 -04:00
|
|
|
|
|
|
|
|
|
gl.short_line_list = {" "} -- keeping this table { } as empty will show inactive statuslines
|
2021-03-07 09:22:30 -05:00
|
|
|
|
|
|
|
|
|
local colors = {
|
2021-04-05 22:59:37 -04:00
|
|
|
|
bg = "#1e222a",
|
|
|
|
|
line_bg = "#1e222a",
|
2021-03-12 20:23:02 -05:00
|
|
|
|
fg = "#D8DEE9",
|
|
|
|
|
fg_green = "#65a380",
|
|
|
|
|
yellow = "#A3BE8C",
|
|
|
|
|
cyan = "#22262C",
|
|
|
|
|
darkblue = "#61afef",
|
|
|
|
|
green = "#BBE67E",
|
|
|
|
|
orange = "#FF8800",
|
|
|
|
|
purple = "#252930",
|
|
|
|
|
magenta = "#c678dd",
|
|
|
|
|
blue = "#22262C",
|
|
|
|
|
red = "#DF8890",
|
2021-04-05 22:59:37 -04:00
|
|
|
|
lightbg = "#282c34",
|
2021-03-12 20:23:02 -05:00
|
|
|
|
nord = "#81A1C1",
|
|
|
|
|
greenYel = "#EBCB8B"
|
2021-03-07 09:22:30 -05:00
|
|
|
|
}
|
|
|
|
|
|
2021-03-08 00:24:53 -05:00
|
|
|
|
gls.left[1] = {
|
2021-03-12 20:23:02 -05:00
|
|
|
|
leftRounded = {
|
|
|
|
|
provider = function()
|
|
|
|
|
return ""
|
|
|
|
|
end,
|
|
|
|
|
highlight = {colors.nord, colors.bg}
|
|
|
|
|
}
|
2021-03-08 00:24:53 -05:00
|
|
|
|
}
|
|
|
|
|
|
2021-03-07 09:22:30 -05:00
|
|
|
|
gls.left[2] = {
|
2021-04-02 01:36:20 -04:00
|
|
|
|
statusIcon = {
|
2021-03-12 20:23:02 -05:00
|
|
|
|
provider = function()
|
|
|
|
|
return " "
|
|
|
|
|
end,
|
|
|
|
|
highlight = {colors.bg, colors.nord},
|
|
|
|
|
separator = " ",
|
|
|
|
|
separator_highlight = {colors.lightbg, colors.lightbg}
|
|
|
|
|
}
|
2021-03-07 09:22:30 -05:00
|
|
|
|
}
|
|
|
|
|
|
2021-03-12 20:23:02 -05:00
|
|
|
|
gls.left[3] = {
|
|
|
|
|
FileIcon = {
|
|
|
|
|
provider = "FileIcon",
|
|
|
|
|
condition = buffer_not_empty,
|
|
|
|
|
highlight = {require("galaxyline.provider_fileinfo").get_file_icon_color, colors.lightbg}
|
|
|
|
|
}
|
2021-03-07 09:22:30 -05:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
gls.left[4] = {
|
2021-03-12 20:23:02 -05:00
|
|
|
|
FileName = {
|
|
|
|
|
provider = {"FileName", "FileSize"},
|
|
|
|
|
condition = buffer_not_empty,
|
|
|
|
|
highlight = {colors.fg, colors.lightbg}
|
|
|
|
|
}
|
2021-03-07 09:22:30 -05:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
gls.left[5] = {
|
2021-03-12 20:23:02 -05:00
|
|
|
|
teech = {
|
|
|
|
|
provider = function()
|
|
|
|
|
return ""
|
|
|
|
|
end,
|
|
|
|
|
separator = " ",
|
|
|
|
|
highlight = {colors.lightbg, colors.bg}
|
|
|
|
|
}
|
2021-03-08 00:24:53 -05:00
|
|
|
|
}
|
|
|
|
|
|
2021-03-07 09:22:30 -05:00
|
|
|
|
local checkwidth = function()
|
2021-03-12 20:23:02 -05:00
|
|
|
|
local squeeze_width = vim.fn.winwidth(0) / 2
|
|
|
|
|
if squeeze_width > 40 then
|
|
|
|
|
return true
|
|
|
|
|
end
|
|
|
|
|
return false
|
2021-03-07 09:22:30 -05:00
|
|
|
|
end
|
|
|
|
|
|
2021-03-08 02:34:48 -05:00
|
|
|
|
gls.left[6] = {
|
2021-03-12 20:23:02 -05:00
|
|
|
|
DiffAdd = {
|
|
|
|
|
provider = "DiffAdd",
|
|
|
|
|
condition = checkwidth,
|
|
|
|
|
icon = " ",
|
|
|
|
|
highlight = {colors.greenYel, colors.line_bg}
|
|
|
|
|
}
|
2021-03-07 09:22:30 -05:00
|
|
|
|
}
|
|
|
|
|
|
2021-03-08 02:34:48 -05:00
|
|
|
|
gls.left[7] = {
|
2021-03-12 20:23:02 -05:00
|
|
|
|
DiffModified = {
|
|
|
|
|
provider = "DiffModified",
|
|
|
|
|
condition = checkwidth,
|
|
|
|
|
icon = " ",
|
|
|
|
|
highlight = {colors.orange, colors.line_bg}
|
|
|
|
|
}
|
2021-03-07 09:22:30 -05:00
|
|
|
|
}
|
|
|
|
|
|
2021-03-08 02:34:48 -05:00
|
|
|
|
gls.left[8] = {
|
2021-03-12 20:23:02 -05:00
|
|
|
|
DiffRemove = {
|
|
|
|
|
provider = "DiffRemove",
|
|
|
|
|
condition = checkwidth,
|
|
|
|
|
icon = " ",
|
|
|
|
|
highlight = {colors.red, colors.line_bg}
|
|
|
|
|
}
|
2021-03-07 09:22:30 -05:00
|
|
|
|
}
|
|
|
|
|
|
2021-03-08 02:34:48 -05:00
|
|
|
|
gls.left[9] = {
|
2021-03-12 20:23:02 -05:00
|
|
|
|
LeftEnd = {
|
|
|
|
|
provider = function()
|
|
|
|
|
return " "
|
|
|
|
|
end,
|
|
|
|
|
separator = " ",
|
|
|
|
|
separator_highlight = {colors.line_bg, colors.line_bg},
|
|
|
|
|
highlight = {colors.line_bg, colors.line_bg}
|
|
|
|
|
}
|
2021-03-07 09:22:30 -05:00
|
|
|
|
}
|
|
|
|
|
|
2021-03-08 02:34:48 -05:00
|
|
|
|
gls.left[10] = {
|
2021-03-12 20:23:02 -05:00
|
|
|
|
DiagnosticError = {
|
|
|
|
|
provider = "DiagnosticError",
|
|
|
|
|
icon = " ",
|
|
|
|
|
highlight = {colors.red, colors.bg}
|
|
|
|
|
}
|
2021-03-07 09:22:30 -05:00
|
|
|
|
}
|
|
|
|
|
|
2021-03-08 02:34:48 -05:00
|
|
|
|
gls.left[11] = {
|
2021-03-12 20:23:02 -05:00
|
|
|
|
Space = {
|
|
|
|
|
provider = function()
|
|
|
|
|
return " "
|
|
|
|
|
end,
|
|
|
|
|
highlight = {colors.line_bg, colors.line_bg}
|
|
|
|
|
}
|
2021-03-07 09:22:30 -05:00
|
|
|
|
}
|
|
|
|
|
|
2021-03-08 02:34:48 -05:00
|
|
|
|
gls.left[12] = {
|
2021-03-12 20:23:02 -05:00
|
|
|
|
DiagnosticWarn = {
|
|
|
|
|
provider = "DiagnosticWarn",
|
|
|
|
|
icon = " ",
|
|
|
|
|
highlight = {colors.blue, colors.bg}
|
|
|
|
|
}
|
2021-03-07 09:22:30 -05:00
|
|
|
|
}
|
|
|
|
|
|
2021-03-08 00:24:53 -05:00
|
|
|
|
gls.right[1] = {
|
2021-03-12 20:23:02 -05:00
|
|
|
|
GitIcon = {
|
|
|
|
|
provider = function()
|
|
|
|
|
return " "
|
|
|
|
|
end,
|
|
|
|
|
condition = require("galaxyline.provider_vcs").check_git_workspace,
|
|
|
|
|
highlight = {colors.green, colors.line_bg}
|
|
|
|
|
}
|
2021-03-08 02:34:48 -05:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
gls.right[2] = {
|
2021-03-12 20:23:02 -05:00
|
|
|
|
GitBranch = {
|
|
|
|
|
provider = "GitBranch",
|
|
|
|
|
condition = require("galaxyline.provider_vcs").check_git_workspace,
|
|
|
|
|
highlight = {colors.green, colors.line_bg}
|
|
|
|
|
}
|
2021-03-08 02:34:48 -05:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
gls.right[3] = {
|
2021-03-12 20:23:02 -05:00
|
|
|
|
right_LeftRounded = {
|
|
|
|
|
provider = function()
|
|
|
|
|
return ""
|
|
|
|
|
end,
|
|
|
|
|
separator = " ",
|
|
|
|
|
separator_highlight = {colors.bg, colors.bg},
|
|
|
|
|
highlight = {colors.red, colors.bg}
|
|
|
|
|
}
|
2021-03-08 00:24:53 -05:00
|
|
|
|
}
|
|
|
|
|
|
2021-03-08 02:34:48 -05:00
|
|
|
|
gls.right[4] = {
|
2021-04-02 01:36:20 -04:00
|
|
|
|
ViMode = {
|
2021-03-12 20:23:02 -05:00
|
|
|
|
provider = function()
|
|
|
|
|
local alias = {
|
|
|
|
|
n = "NORMAL",
|
|
|
|
|
i = "INSERT",
|
|
|
|
|
c = "COMMAND",
|
|
|
|
|
V = "VISUAL",
|
|
|
|
|
[""] = "VISUAL",
|
|
|
|
|
v = "VISUAL",
|
|
|
|
|
R = "REPLACE"
|
|
|
|
|
}
|
|
|
|
|
return alias[vim.fn.mode()]
|
|
|
|
|
end,
|
|
|
|
|
highlight = {colors.bg, colors.red}
|
|
|
|
|
}
|
2021-03-07 09:22:30 -05:00
|
|
|
|
}
|
|
|
|
|
|
2021-03-08 02:34:48 -05:00
|
|
|
|
gls.right[5] = {
|
2021-03-12 20:23:02 -05:00
|
|
|
|
PerCent = {
|
|
|
|
|
provider = "LinePercent",
|
|
|
|
|
separator = " ",
|
|
|
|
|
separator_highlight = {colors.red, colors.red},
|
|
|
|
|
highlight = {colors.bg, colors.fg}
|
|
|
|
|
}
|
2021-03-07 09:22:30 -05:00
|
|
|
|
}
|
2021-03-08 01:19:27 -05:00
|
|
|
|
|
2021-03-08 02:34:48 -05:00
|
|
|
|
gls.right[6] = {
|
2021-03-12 20:23:02 -05:00
|
|
|
|
rightRounded = {
|
|
|
|
|
provider = function()
|
|
|
|
|
return ""
|
|
|
|
|
end,
|
|
|
|
|
highlight = {colors.fg, colors.bg}
|
|
|
|
|
}
|
2021-03-08 01:19:27 -05:00
|
|
|
|
}
|