vim-one
vim-one copied to clipboard
Odd grey background in "git commit -v"
I just switched to vim-one following the instructions on the README.md.
I've also added xterm-256colors-italic support to get italics (which works 90% the time)
When I went to commit some changes (using -v to see the diff) I was presented with this odd grey background on the changes.
I am not using tmux, Neovim 0.2.2 iTerm2 Build 3.1.5
Snippet from my ~/.config/nvim/init.vim
set termguicolors
colorscheme one
set background=light
let g:one_allow_italics=1
highlight Comment cterm=italic
let g:airline_theme='one'
Hi, nothing seems to be wrong in your screenshot. By design the diffs do have a grey background.
call <sid>X('DiffAdd', s:hue_4, s:visual_grey, '')
call <sid>X('DiffChange', s:hue_6, s:visual_grey, '')
call <sid>X('DiffDelete', s:hue_5, s:visual_grey, '')
call <sid>X('DiffText', s:hue_2, s:visual_grey, '')
call <sid>X('DiffAdded', s:hue_4, s:visual_grey, '')
call <sid>X('DiffFile', s:hue_5, s:visual_grey, '')
call <sid>X('DiffNewFile', s:hue_4, s:visual_grey, '')
call <sid>X('DiffLine', s:hue_2, s:visual_grey, '')
call <sid>X('DiffRemoved', s:hue_5, s:visual_grey, '')
You can change the background in your vimrc/vim/init.vim using like so:
call one#highlight('DiffDelete, '', '', 'none')
Thank you @rakr for the swift response.
After adding all of those - changing them to one#highlight(...) I still see the gray background:
These are my settings:
set termguicolors
colorscheme one
set background=light
let g:one_allow_italics=1
let g:airline_theme='one'
call one#highlight('DiffDelete', '', '', 'none')
call one#highlight('DiffAdd', '', '', 'none')
call one#highlight('DiffChange', '', '', 'none')
call one#highlight('DiffDelete', '', '', 'none')
call one#highlight('DiffText', '', '', 'none')
call one#highlight('DiffAdded', '', '', 'none')
call one#highlight('DiffFile', '', '', 'none')
call one#highlight('DiffNewFile','', '', 'none')
call one#highlight('DiffLine', '', '', 'none')
call one#highlight('DiffRemoved','', '', 'none')
What would a vim command be to check if these are having any effect?
Adding above lines did have no effect on my diffs 😢
I had unwanted gray backgrounds when italics were enabled; you could try disabling those.