Skip to content

Commit

Permalink
Merge pull request #140 from ful1e5/main
Browse files Browse the repository at this point in the history
Link common highlights for `diff` group
  • Loading branch information
ful1e5 committed Dec 4, 2021
2 parents 87106dd + d5f39b6 commit d1b2b7f
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 12 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- enhance: `StatusLine` foreground & `StatusLineNC` background colors are customizable ( related to #11 )
- feat: vscode like lspkind highlighting inside `nvim-cmp` #137
- enhance: highlight all lspkind list in `nvim-cmp` #137
- Link common highlights for `diff` group

### Fixes

Expand Down
24 changes: 12 additions & 12 deletions lua/github-theme/theme.lua
Original file line number Diff line number Diff line change
Expand Up @@ -19,22 +19,22 @@ function M.setup(config)
ColorColumn = {bg = c.bg_visual}, -- used for the columns set with 'colorcolumn'
Conceal = {fg = c.fg_gutter}, -- placeholder characters substituted for concealed text (see 'conceallevel')
Cursor = {fg = c.bg, bg = c.fg}, -- character under the cursor
lCursor = {fg = c.bg, bg = c.fg}, -- the character under the cursor when |language-mapping| is used (see 'guicursor')
CursorIM = {fg = c.bg, bg = c.fg}, -- like Cursor, but used when in IME mode |CursorIM|
lCursor = {link = "Cursor"}, -- the character under the cursor when |language-mapping| is used (see 'guicursor')
CursorIM = {link = "Cursor"}, -- like Cursor, but used when in IME mode |CursorIM|
CursorColumn = {bg = c.bg_highlight}, -- Screen-column at the cursor, when 'cursorcolumn' is set.
CursorLine = {bg = c.bg_highlight}, -- Screen-line at the cursor, when 'cursorline' is set. Low-priority if foreground (ctermfg OR guifg) is not set.
CursorLine = {link = "CursorColumn"}, -- Screen-line at the cursor, when 'cursorline' is set. Low-priority if foreground (ctermfg OR guifg) is not set.
Directory = {fg = c.blue}, -- directory names (and other special names in listings)
DiffAdd = {bg = c.diff.add}, -- diff mode: Added line |diff.txt|
DiffChange = {bg = c.diff.change}, -- diff mode: Changed line |diff.txt|
DiffDelete = {bg = c.diff.delete}, -- diff mode: Deleted line |diff.txt|
DiffAdd = {fg = c.diff.add_fg, bg = c.diff.add}, -- diff mode: Added line |diff.txt|
DiffChange = {fg = c.diff.change_fg, bg = c.diff.change}, -- diff mode: Changed line |diff.txt|
DiffDelete = {fg = c.diff.delete_fg, bg = c.diff.delete}, -- diff mode: Deleted line |diff.txt|
DiffText = {fg = c.fg_gutter}, -- diff mode: Changed text within a changed line |diff.txt|
EndOfBuffer = {fg = c.eob}, -- filler lines (~) after the end of the buffer. By default, this is highlighted like |hl-NonText|.
-- TermCursor = { }, -- cursor in a focused terminal
-- TermCursorNC= { }, -- cursor in an unfocused terminal
ErrorMsg = {fg = c.error}, -- error messages on the command line
VertSplit = {fg = c.bg_visual, bg = c.bg}, -- the column separating vertically split windows
Folded = {fg = c.fg_folded, bg = c.bg_folded}, -- line used for closed folds
FoldColumn = {fg = c.fg_folded, bg = c.bg_folded}, -- 'foldcolumn'
FoldColumn = {link = "Folded"}, -- 'foldcolumn'
SignColumn = {bg = config.transparent and c.none or c.bg, fg = c.fg_gutter}, -- column where |signs| are displayed
SignColumnSB = {bg = c.bg_sidebar, fg = c.fg_gutter}, -- column where |signs| are displayed
Substitute = {bg = c.red, fg = c.black}, -- |:substitute| replacement text highlighting
Expand Down Expand Up @@ -350,9 +350,9 @@ function M.setup(config)
illuminatedCurWord = {bg = c.lsp.referenceText},

-- diff
diffAdded = {bg = c.diff.add, fg = c.diff.add_fg},
diffRemoved = {bg = c.diff.delete, fg = c.diff.delete_fg},
diffChanged = {bg = c.diff.change, fg = c.diff.change_fg},
diffAdded = {link = "DiffAdd"},
diffChanged = {link = "DiffChange"},
diffRemoved = {link = "DiffDelete"},
diffOldFile = {fg = c.yellow},
diffNewFile = {fg = c.orange},
diffFile = {fg = c.blue},
Expand All @@ -365,8 +365,8 @@ function M.setup(config)
NeogitHunkHeader = {bg = c.bg_highlight, fg = c.fg},
NeogitHunkHeaderHighlight = {bg = c.bg_highlight, fg = c.blue, style = "italic"},
NeogitDiffContextHighlight = {bg = c.bg, fg = c.fg},
NeogitDiffDeleteHighlight = {fg = c.diff.delete_fg, bg = c.diff.delete},
NeogitDiffAddHighlight = {fg = c.diff.add_fg, bg = c.diff.add},
NeogitDiffAddHighlight = {link = "DiffAdd"},
NeogitDiffDeleteHighlight = {link = "DiffDelete"},

-- GitGutter
GitGutterAdd = {fg = c.git_signs.add}, -- diff mode: Added line |diff.txt|
Expand Down

0 comments on commit d1b2b7f

Please sign in to comment.