Coder Social home page Coder Social logo

vim-gruvbox8's Introduction

Gruvbox 8 - Vim Color Scheme

Note: if you are using Neovim, checkout the neovim branch of this repo.

This is a simplified and optimized* version of Gruvbox that I have developed to address some issues I had with the official color scheme.

These are the main differences compared to the official Gruvbox:

  • by default, no plugin and filetype highlight groups to avoid messing up syntax highlighting after switching color schemes (they can be enabled through options);
  • reduced number of options;
  • all options are documented;
  • slightly different (and, IMHO, better) 256-color palette;
  • gracefully degrades to 16, 8 or even only 2 colors;
  • support for transparent backgrounds in terminals;
  • no shell scripts;
  • up to date highlight group definitions (e.g., includes ToolbarLine and ToolbarButton);
  • defines g:terminal_ansi_colors;
  • generated by Colortemplate, i.e., easily hackable.

* Below is the result of a benchmark made using Vim 8.1.1550 and iTerm 2 v3.2.9 on a MacBook Pro Early 2015 with macOS 10.14.5. Note that Gruvbox 8 is optimized for what are believed to be the most common use cases, i.e., GUI, true-color terminals and 256-color terminals.

True-color Variants

256-color Variants

Less capable terminals

Earlier versions of Gruvbox 8 would complain when the terminal did not have enough colors. This is no longer the case: Gruvbox 8 will gracefully degrade to 16, 8 or even 2 colors, as illustrated by the screenshot below:

Hacking

Do you want to hack the theme? Install Colortemplate, edit the files in the templates folder, then rebuild the color schemes.

vim-gruvbox8's People

Contributors

antoinemadec avatar binarypie avatar casonadams avatar dmbfm avatar kristijanhusak avatar lifepillar avatar logarithmus avatar pangpangpangpangpang avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

vim-gruvbox8's Issues

Strange behaviour of left service column

Hello.

neovim 0.5

I've noticed some strange colors on service column which usually used for git signs , lsp-errors and so on.

Take a look at the screenshot please:
image

I use this plugin for git signs https://github.com/lewis6991/gitsigns.nvim but it's similar with vim-signify
image

Look like it is inversion of colors.

Also please take a look at unused part of that column. Should this color be different from background?
image

Just to say thank you

I didn't find a better way to communicate with you, so here I am.

This version of gruvbox is a bijou.

Thanks

Feel free to close, delete or do (anyway) whatever you like with this issue.

I'm satisfied by design ;-)

Digraph table characters hard to see

When issuing the command :digraphs, the output is this:
image

The digraph characters are hard to see. I understand that the highlight group for these is SpecialKey. I can work on this later this week, by just increasing the contrast, but is there anything else I should know about it?

the color of startify not normal

hi, i use gruvbox8, nice colorscheme. but i found the color not normal .you can see this pic
1123

i found the color in _plugins.colortemplate

# Startify {{{
StartifyBracket                  fg3    none
StartifyFile                     fg1    none
StartifyNumber                   blue   none
StartifyPath                     grey   none
StartifySlash                    grey   none
StartifySection                  yellow none
StartifySpecial                  bg2    none
StartifyHeader                   orange none
StartifyFooter                   bg2    none
# }}}

the startify Header is orange but i got green?

my config

i use dein

[[plugins]]
repo = 'lifepillar/vim-gruvbox8'
hook_add = '''
let g:gruvbox_filetype_hi_groups = 1
let g:gruvbox_plugins_hi_groups = 1
'''
colorscheme gruvbox8_hard

i change the value of g:gruvbox_plugins_hi_groups but nothing change

Failed to disable italics

I want to set it as the default font, but I don’t want to set italics
I used the option but it didn’t work

let g:gruvbox_italicize_strings = 0

let g:gruvbox_italics = 0

How should I do?
Screenshot_20210403_145314

Vim built-in terminal is not transparent

The background of built-in terminal is not transparent after setting let g:gruvbox_transp_bg = 1

:hi Terminal
Terminal       xxx ctermfg=187 ctermbg=235 guifg=#ebdbb2 guibg=#282828

Lua port

Hey. I see you care about perfomance in your colorscheme. I heard lua-based plugins could be even faster! Neovim 0.5 supports it.
Do you have any plans to port this scheme to lua? Is it make sense?

cant get operators highlight in go file

hi i use vim -go and have this setting let g:go_highlight_operators = 1 . i cant get any operators highlight in go file when use gruvbox8. my gruvbox8 set

 [[plugins]]
 repo = 'lifepillar/vim-gruvbox8'
 hook_add = '''
  let g:gruvbox_filetype_hi_groups = 1
  let g:gruvbox_plugin_hi_groups = 1
'''

term

Changing colors for lsp warnings and errors

Errors and warning given by lsp are all white. With gruvbox-community/gruvbox If we add

if exists('+termguicolors')
    let &t_8f = "\<Esc>[38;2;%lu;%lu;%lum"
    let &t_8b = "\<Esc>[48;2;%lu;%lu;%lum"
endif

this seems to work but not working for gruvbox8. Am I doing something wrong?
My terminal is alacrity, I also tried in gnome-terminal

Missing comma in template

#if get(g: '@optionprefix_invert_indent_guides', 0)

This line:

if get(g: 'gruvbox_invert_indent_guides', 0)`

is missing a comma after the g: in this function call.

This causes a syntax error when the variable indent_guides_auto_colors is set to true.

SignColumn bg color

i checked the bg of SignColumn is none . but i got bg color. dont know what happend
2

The theme seems to not work

Hello, I use the last version of Neovim in Neovide on Windows 10 and I can't get the theme to work.

arf

I tried several things but the only one that works is to call "colorscheme gruvbox8" by hand once nvim started so it's not really usable.

Use Nvim in another terminal like Powershell or Alacritty is the same.

Enabling filetype and plugin highlights

Hi,

i noticed that highlights for filetype and plugin exists in the templates, but they are not part of the colorscheme.
Is there a way to add it to the colorscheme, except building the colorscheme by myself?

Theme doesn't load automatically upon start up when using a lua config

I'm using a lua config in the nightly build of neovim. For some reason, neovim loads the default theme instead of gruvbox8 whenever I start it up; I have to do a ":luafile ~/.config/nvim/init.lua" for it to load. I've done some testing, and this problem only happens with gruvbox8 and only when using an init.lua. Here's the line I use to set the colorscheme in my config:

vim.api.nvim_command "colors gruvbox8"

Any idea of what's going on?

(P.S.: english is not my native language, sorry if I've made some mistake)

Fallback colors

Hello,

I really hope if you can help me figure out how do you make your theme fallback to 2 colors

do you use

set t_Co=2

I tried it and it didn't work for me. Thank you

Turn of italics for String

Hey 👋,

Firstly I'd like to give a thank you for this very speedy gruvbox theme!

I don't want italics for my strings and tried disabling it with let g:gruvbox_italicize_strings = 0. This disables italics for strings but also for specials, see https://github.com/lifepillar/vim-gruvbox8/blob/master/colors/gruvbox8.vim#L152.

My guess is that this is a bug? Adding this the below 👇 to my vimrc solves it for me at least.

" Turn of italics for strings.
hi! String gui=NONE cterm=NONE

fzf windows open in dark mode

Hi,

I've noticed a few days ago that fzf windows (:Files, :Buffers) now open with dark colors. It doesn't happen with other colorschemes though.

I'm running vim 9.0.1600 on kitty 0.28.1.

How can I disable italics?

With the gruvbox theme I can disable italics with:

" gruvbox colour scheme
let g:gruvbox_italic = 0

How can I do this with gruvbox8?


EDIT: Actually I have just realised that this setting doesn't seem to do anything, and I don't get italics either way. But in any case, I would prefer to not have any italics anywhere in vim, as I find them too distracting as they seem to appear in more than just comments.

Or, alternatively, how can I disable italics within single quotes?

Set Airline Theme

Greetings,

In the pictures in README.md there seems to be some status line plugin. I'd like to know which one and how can I set the theme to gruvbox8.

Thanks in advance,

MyriadAsura

E121: Undefined variable and E15: Invalid expression errors

I get this error when I set g:gruvbox_plugin_hi_groups to 1:

Error detected while processing /home/???/.local/share/nvim/bundle/vim-gruvbox8/colors/gruvbox8_hard.vim:
line  235:
E121: Undefined variable: #504945
E15: Invalid expression: #504945
line  850:
E121: Undefined variable: #d5c4a1
E15: Invalid expression: #d5c4a1

I think you must use strings in the templates.
Example _plugins.colortemplate line: 73:

let g:indentLine_color_gui = '@guibg2'

When using gruvbox8_soft and scrolling away, the background color is only partially applied

When I load a file using the gruvbox8_soft, only the initial screen has the background colors I expect. When scrolling away, only the code bits have the correct background color and the parts of the screen with no characters just have the normal gruvbox8 (not soft) background color. Refreshing with corrects things, but it's annoying to do this every time.

As a side note, this is in the kitty terminal. The issue does not present itself with gvim.

Here is a video

gruvbox-2022-12-10_19.18.27.mp4

gruvbox_transp_bg=1 doesn't work in Neovim 0.6

Hello. After some updates I noticed that transparent become unavailable.

vim.o.termguicolors=true
vim.cmd [[ colorscheme gruvbox8 ]]
vim.g.gruvbox_transp_bg=1

this code worked before in nvim but now it doesn't.

This plugin does not work well for Markdown files when switch back and forth between different color schemes

The behavior of this plugin is different from that of the original gruvbox colorscheme. When switching from other colorscheme to gruvbox8, highlight for header, inline link, inline code will lost, resulting a Markdown file barely readable. The original gruvbox colorscheme does not exhibit this behavior.

To reproduce, use the following minimal config:

set runtimepath+=/path/to/gruvbox8
set runtimepath+=/path/to/original/gruvbox
  • Open neovim with nvim -u minimal.vim test.md.
  • Switch to gruvbox colorsheme :color gruvbox. The highlight for header, inlink link etc. works.
  • Switch to gruvbox8 colorshceme :color gruvbox8. The highlight for header, inlink link etc. is lost. All text are now in plain color.

The content of test.md:

# demo header

inline link: [some links](http://www.foobar.com)
inline code: `a=a+c`

Latest update causes wrong colors

After updating to the latest (the commit with migrating to Colortemplates v2), the colorscheme is way off. It's not even gruvbox anymore:

Some javascript:
image

A piece of my .vimrc:
image

I'm using nvim v0.3.7 on iTerm2 3.2.9. What other info can I give you to make this easier to debug?

Treesitter support

First off, great theme, been using it for a while and the startup time difference is noticeable.

Seeing as there is support for a variety of plugins already, supporting treesitter explicitly would be great. There are already quite a few colorschemes explicitly supporting treesitter.

Just bear in mind, treesitter is a neovim only tool, and the integration will ship with neovim in the 5.0 release.

upon vim startup, bright color theme for a split second, then dark?

Hey,

first: many thanks for the great colorscheme!

I am having one issue though that I'd like to understand.

With the following settings:

Plug "ifepillar/vim-gruvbox8"
" ...
colorscheme gruvbox8_hard

Now, if I open vim via tmux, I will see the bright theme.

If I open vim outside tmux I see the bright theme at startup for a very split moment, and then the dark (expected) theme.

I wonder what is happening internally of vim-gruvbox8 to do that, would you mind giving me some hints?

Many thanks, and marry Christmas.

Colors table

Thanks for the remarkable classic vim theme revamp. It's noticed that palette was improved in 256-colour-terminals. I would like to know which colours were tweaked. Having a colours table like in gruvbox-contrib would help to use those colours in other projects (personally I need that for kitty, delta and tig) :D

Preview Window Highlight

Neovim 0.5, 0.6 - happens on all

Awesome color scheme!
One problem - on the pop up preview for functions, etc. everything but the parentheses are highlighted. Just a slight annoyance.

Behavior of morhetz/gruvbox:
image

Behavior of lifepillar/vim-gruvbox8:
image

Even if its just a slight highlight line into my config, how can I fix this?

gruvbox8 theme for bat?

I'm using bat for text previewing in ranger, fzf.vim, etc.
I wonder if there's a gruvbox8 theme for bat?

Add Support for coc-vim

Add colorsetting for the following:

CocErrorSign 
CocWarningSign 
CocInfoSign 
CocHintSign 
CocErrorFloat 
CocWarningFloat 
CocInfoFloat 
CocHintFloat 
CocDiagnosticsError 
CocDiagnosticsWarning 
CocDiagnosticsInfo 
CocDiagnosticsHint 

CocSelectedText 
CocCodeLens 

CocErrorHighlight
CocWarningHighlight
CocInfoHighlight
CocHintHighlight

See gruvbox
lines 895 - 914

Poor readability of conceal characters

conceal characters looks like this:
image
the color is pretty close to the background and thus not readable

:hi conceal
Conceal        xxx ctermfg=239 guifg=#504945

Light theme for lightline

There's only the dark theme for lightline.
I've tried to edit templates and build it, but...

templates/_lightline:

Include: _dark
auxfile autoload/lightline/colorscheme/@shortname.vim
if &background == "dark"
    let s:bg0 = [ '@guibg0', @term256bg0 ]
    let s:bg1 = [ '@guibg1', @term256bg1 ]
    let s:bg2 = [ '@guibg2', @term256bg2 ]
    let s:bg4 = [ '@guibg4', @term256bg4 ]
    let s:fg1 = [ '@guifg1', @term256fg1 ]
    let s:fg4 = [ '@guifg4', @term256fg4 ]
endauxfile

Include: _light
auxfile autoload/lightline/colorscheme/@shortname.vim
else
    let s:bg0 = [ '@guibg0', @term256bg0 ]
    let s:bg1 = [ '@guibg1', @term256bg1 ]
    let s:bg2 = [ '@guibg2', @term256bg2 ]
    let s:bg4 = [ '@guibg4', @term256bg4 ]
    let s:fg1 = [ '@guifg1', @term256fg1 ]
    let s:fg4 = [ '@guifg4', @term256fg4 ]
endif
endauxfile

auxfile autoload/lightline/colorscheme/@shortname.vim
let s:green  = [ '@guineutralgreen', @term256neutralgreen ]
let s:yellow = [ '@guineutralyellow', @term256neutralyellow ]
let s:blue   = [ '@guineutralblue', @term256neutralblue ]
...

it gives me a lot of errors about the already defined colors:
image

Any idea? I'd appreciate any answer :)

Few enhancements?

I recently switched from gruvbox-community and I am liking the slightly different color palette. But there are two things which I find missing.

  1. It's very hard to figure out on what highlighted match your cursor is? Earlier I had let g:gruvbox_hls_cursor='blue' in gruvbox-community which made it easier to see!

  2. An option to disable bold text, which again I could disable by let g:gruvox_bold=0 earlier.

Will it be possible to have these features in gruvbox8?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.