From d00787254c5417dda002c94028bdf6b0079bd3e9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ellison=20Lea=CC=83o?= Date: Sat, 8 Jan 2022 18:39:29 -0300 Subject: removing lightline custom code This is no longer necessary since lualine plugin already supports the gruvbox theme out of the box --- lua/gruvbox/init.lua | 3 -- lua/gruvbox/plugins/lightline.lua | 73 --------------------------------------- 2 files changed, 76 deletions(-) delete mode 100644 lua/gruvbox/plugins/lightline.lua (limited to 'lua') diff --git a/lua/gruvbox/init.lua b/lua/gruvbox/init.lua index 1d49180..eb9ff71 100644 --- a/lua/gruvbox/init.lua +++ b/lua/gruvbox/init.lua @@ -11,7 +11,4 @@ M.load = function() utils.highlights(spec) end --- checking if user has lightline and adding support -require("gruvbox.plugins.lightline").init(spec) - return M diff --git a/lua/gruvbox/plugins/lightline.lua b/lua/gruvbox/plugins/lightline.lua deleted file mode 100644 index 53e9180..0000000 --- a/lua/gruvbox/plugins/lightline.lua +++ /dev/null @@ -1,73 +0,0 @@ --- lightline support -local M = {} - -M.init = function(theme) - local has_lightline, _ = pcall(vim.fn["lightline#update"]) - if not has_lightline then - return - end - - local bg0 = theme.GruvboxBg0.fg - local bg1 = theme.GruvboxBg1.fg - local bg2 = theme.GruvboxBg2.fg - local bg4 = theme.GruvboxBg4.fg - local fg1 = theme.GruvboxFg1.fg - local fg4 = theme.GruvboxFg4.fg - - local yellow = theme.GruvboxYellow.fg - local blue = theme.GruvboxBlue.fg - local aqua = theme.GruvboxAqua.fg - local orange = theme.GruvboxOrange.fg - local red = theme.GruvboxRed.fg - local green = theme.GruvboxGreen.fg - - local lightline_theme = { - normal = { - left = { { bg0, fg4, "bold" }, { fg4, bg2 } }, - middle = { { fg4, bg1 } }, - right = { { bg0, fg4 }, { fg4, bg2 } }, - error = { { bg0, red } }, - warning = { { bg0, yellow } }, - }, - insert = { - left = { { bg0, blue, "bold" }, { fg1, bg2 } }, - middle = { { fg4, bg1 } }, - right = { { bg0, blue }, { fg1, bg2 } }, - }, - inactive = { - left = { { bg4, bg1 } }, - middle = { { bg4, bg1 } }, - right = { { bg4, bg1 }, { bg4, bg1 } }, - }, - terminal = { - left = { { bg0, green, "bold" }, { fg1, bg2 } }, - middle = { { fg4, bg1 } }, - right = { { bg0, green }, { fg1, bg2 } }, - }, - replace = { - left = { { bg0, aqua, "bold" }, { fg1, bg2 } }, - middle = { { fg4, bg1 } }, - right = { { bg0, aqua }, { fg1, bg2 } }, - }, - visual = { - left = { { bg0, orange, "bold" }, { bg0, bg4 } }, - middle = { { fg4, bg1 } }, - right = { { bg0, orange }, { bg0, bg4 } }, - }, - tabline = { - left = { { fg4, bg2 } }, - middle = { { bg0, bg4 } }, - right = { { bg0, orange } }, - tabsel = { { bg0, fg4 } }, - }, - } - - local ll_filled = vim.fn["lightline#colorscheme#fill"](lightline_theme) - vim.g["lightline#colorscheme#gruvbox#palette"] = ll_filled - vim.schedule(function() - vim.fn["lightline#disable"]() - vim.fn["lightline#enable"]() - end) -end - -return M -- cgit v1.2.3