Home > OS >  Gruvbox colorscheme not applying
Gruvbox colorscheme not applying

Time:11-14

So, I tried applying gruvbox color scheme in neovim. But I'm getting errors saying it can't find gruvbox color scheme. There is code:

set termguicolors
let g:gruvbox_contrast_dark='medium'
let g:gruvbox_contrast_light='hard'
colorscheme gruvbox
hi LspCxxHlGroupMemberVariable guifg=#83a598

and snippet of plugins.lua:

return require('packer').startup(function()
  use 'morhetz/gruvbox'
end)

I tried adding: g:gruvbox_termcolors=256

But it didn't work.

Error: E185: Cannot find color scheme 'gruvbox'

CodePudding user response:

would be great if you can share you config with us so we can help you, I'm also using gruvbox but without a problem. Here is some of steps that you can do, I assume you have using lua for your config.

plugin: https://github.com/ellisonleao/gruvbox.nvim

after you add plugin to packer startup fun, run this command to be sure that plugin is installed :PackerSync

after that go into your init.lua file and pass this line of code

vim.o.background = "dark" #you can use dark or light mode.

vim.cmd([[colorscheme gruvbox]])

this should help you to make gruvbox to work.

  • Related