Home

Awesome

Gruvbox Flat

A dark beautiful Neovim theme written in Lua. [Coming soon] extra themes for Kitty and Alacritty

<img width="1680" alt="rust code" src="./media/gruvbox-original.png"> <img width="1680" alt="pallet" src="./media/pallet-gruvbox.png">

✨ Features

Plugin Support

⚡️ Requirements

📦 Installation

Install the theme with your preferred package manager:

vim-plug

Plug 'eddyekofo94/gruvbox-flat.nvim'

packer

use 'eddyekofo94/gruvbox-flat.nvim'

lazy.nvim

return {
    'eddyekofo94/gruvbox-flat.nvim',
    priority = 1000,
    enabled = true,
    config = function()
        vim.cmd([[colorscheme gruvbox-flat]])
    end,
}

🚀 Usage

Enable the colorscheme:

" Vim Script
colorscheme gruvbox-flat
-- Lua
vim.cmd[[colorscheme gruvbox-flat]]

To enable the gruvbox theme for Lualine, simply specify it in your lualine settings:

require('lualine').setup {
  options = {
    theme = 'gruvbox-flat'
    -- ... your lualine config
  }
}

To enable the gruvbox-flat colorscheme for Lightline:

" Vim Script
let g:lightline = {'colorscheme': 'gruvbox-flat'}

To enable darker mode

vim.g.gruvbox_flat_style = "dark"

<img width="1680" alt="rust code" src="./media/gruvbox-dark.png">

To enable harder mode

vim.g.gruvbox_flat_style = "hard"

<img width="1680" alt="harder" src="./media/gruvbox-harder.png">

⚙️ Configuration

❗️ configuration needs to be set BEFORE loading the color scheme with colorscheme gruvbox-flat

OptionDefaultDescription
gruvbox_terminal_colorstrueConfigure the colors used when opening a :terminal in Neovim
gruvbox_italic_commentstrueMake comments italic
gruvbox_italic_keywordstrueMake keywords italic
gruvbox_italic_functionsfalseMake functions italic
gruvbox_italic_variablesfalseMake variables and identifiers italic
gruvbox_transparentfalseEnable this to disable setting the background color
gruvbox_hide_inactive_statuslinefalseEnabling this option, will hide inactive statuslines and replace them with a thin border instead. Should work with the standard StatusLine and LuaLine.
gruvbox_sidebars{}Set a darker background on sidebar-like windows. For example: ["qf", "vista_kind", "terminal", "packer"]
gruvbox_dark_sidebartrueSidebar like windows like NvimTree get a darker background
gruvbox_dark_floattrueFloat windows like the lsp diagnostics windows get a darker background.
gruvbox_colors{}You can override specific color groups to use other groups or a hex color
gruvbox_theme{}You can override specific highlight groups to use other color groups or a hex color
-- Example config in Lua
vim.g.gruvbox_italic_functions = true
vim.g.gruvbox_sidebars = { "qf", "vista_kind", "terminal", "packer" }

-- Change the "hint" color to the "orange" color, and make the "error" color bright red
vim.g.gruvbox_colors = { hint = "orange", error = "#ff0000" }

-- Change the TabLineSel highlight group (used by barbar.nvim) to the "orange" color
vim.g.gruvbox_theme = { TabLineSel = { bg = "orange" } }

-- Load the colorscheme
vim.cmd[[colorscheme gruvbox-flat]]
" Example config in VimScript
let g:gruvbox_italic_functions = 1
let g:gruvbox_sidebars = [ "qf", "vista_kind", "terminal", "packer" ]

" Load the colorscheme
colorscheme gruvbox-flat

Making undercurls work properly in Tmux

To have undercurls show up and in color, add the following to your Tmux config file:

# Undercurl
set -g default-terminal "${TERM}"
set -as terminal-overrides ',*:Smulx=\E[4::%p1%dm'  # undercurl support
set -as terminal-overrides ',*:Setulc=\E[58::2::%p1%{65536}%/%d::%p1%{256}%/%{255}%&%d::%p1%{255}%&%d%;m'  # underscore colours - needs tmux-3.0

🍭 Extras

Extra color configs for Kitty, and Alacritty can be found in extras. To use them, refer to their respective documentation.

<img width="825" alt="Alacritty terminal" src="./media/term-colors.png">

✅ TODO