Something went wrong. Try again.
fork of https://github.com/xzlee3/nvim-github-theme
Something went wrong. Try again.
·
Copy SHA
- Lua 76%
- JavaScript 24%
- Shell <1%
README.md
nvim-github-theme #
GitHub's modern theme variants for Neovim.
Requirements #
- Neovim
0.9+ termguicolorsenabled
Installation #
Install the plugin with your preferred plugin manager, then pick one of the shipped colorschemes:
github_light_defaultgithub_light_high_contrastgithub_light_colorblindgithub_dark_defaultgithub_dark_high_contrastgithub_dark_colorblindgithub_dark_dimmed
Usage #
require("github_theme").setup({
transparent = false,
styles = {
comments = { italic = true },
keywords = { bold = false },
functions = { italic = false },
types = { italic = false },
},
colors = {
comment = "#6e7781",
},
highlights = {
CursorLineNr = { bold = true },
},
})
vim.cmd.colorscheme("github_dark_default")
Configuration #
setup() accepts these options:
{
transparent = false,
styles = {
comments = { italic = false, bold = false, underline = false },
keywords = { italic = false, bold = false, underline = false },
functions = { italic = false, bold = false, underline = false },
types = { italic = false, bold = false, underline = false },
},
colors = {
-- overrides normalized palette keys before highlight compilation
-- for example: bg, fg, comment, string, keyword, type, accent
},
highlights = {
-- overrides final highlight groups after compilation
},
}
Scope #
This port covers:
- core UI groups
- standard Vim syntax groups
- Treesitter captures
- LSP semantic token groups
- diagnostics, diff, git sign groups
- terminal ANSI colors
This first version does not ship third-party plugin adapters.
Updating From Upstream #
The runtime does not depend on Node, but the repo includes a maintenance script for refreshing the generated color intent from the official GitHub VS Code theme and Primer palettes.
Refresh the pinned sources:
node scripts/sync_intent.mjs
Verify the committed generated artifacts still match the pinned upstream versions:
node scripts/sync_intent.mjs --check
Override the upstream versions for a one-off update:
node scripts/sync_intent.mjs --github-vscode-theme 6.3.5 --primer 7.10.0
The pinned defaults live in scripts/sources.json.