Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 7 additions & 2 deletions doc/neogit.txt
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,7 @@ to Neovim users.
initial_branch_name = "",
-- Change the default way of opening neogit
kind = "tab",
-- Floating window style
-- Floating window style
floating = {
relative = "editor",
width = 0.8,
Expand Down Expand Up @@ -680,12 +680,17 @@ these yourself before the plugin loads, that will be respected. If they do not
exist, they will be created with sensible defaults based on your colorscheme.

STATUS BUFFER
NeogitNormal Normal text
NeogitFloat Normal text when using a floating window
NeogitFloatBorder Border wen using a floating window
NeogitBranch Local branches
NeogitBranchHead Accent highlight for current HEAD in LogBuffer
NeogitRemote Remote branches
NeogitObjectId Object's SHA hash
NeogitStash Stash name
NeogitFold Folded text highlight
NeogitFoldColumn Column where folds are displayed
NeogitSignColumn Column where signs are displayed
NeogitRebaseDone Current position within rebase
NeogitTagName Closest Tag name
NeogitTagDistance Number of commits between the tag and HEAD
Expand Down Expand Up @@ -2256,7 +2261,7 @@ Customizing Popups *neogit_custom_popups*

You can customize existing popups via the Neogit config.

Below is an example of adding a custom switch, but you can use any function
Below is an example of adding a custom switch, but you can use any function
from the builder API.
>lua
require("neogit").setup({
Expand Down
4 changes: 4 additions & 0 deletions lua/neogit/lib/buffer.lua
Original file line number Diff line number Diff line change
Expand Up @@ -778,7 +778,11 @@ function Buffer.create(config)
buffer:set_window_option("list", false)
buffer:call(function()
vim.opt_local.winhl:append("Folded:NeogitFold")
vim.opt_local.winhl:append("FoldColumn:NeogitFoldColumn")
vim.opt_local.winhl:append("SignColumn:NeogitSignColumn")
vim.opt_local.winhl:append("Normal:NeogitNormal")
vim.opt_local.winhl:append("NormalFloat:NeogitNormalFloat")
vim.opt_local.winhl:append("FloatBorder:NeogitFloatBorder")
vim.opt_local.winhl:append("WinSeparator:NeogitWinSeparator")
vim.opt_local.winhl:append("CursorLineNr:NeogitCursorLineNr")
vim.opt_local.fillchars:append("fold: ")
Expand Down
4 changes: 4 additions & 0 deletions lua/neogit/lib/hl.lua
Original file line number Diff line number Diff line change
Expand Up @@ -179,6 +179,9 @@ function M.setup(config)
NeogitSignatureGoodExpiredKey = { link = "NeogitGraphYellow" },
NeogitSignatureGoodRevokedKey = { link = "NeogitGraphRed" },
NeogitNormal = { link = "Normal" },
NeogitNormalFloat = { link = "NeogitNormal" },
NeogitFloatBorder = { link = "NeogitNormalFloat" },
NeogitSignColumn = { fg = "None", bg = "None" },
NeogitCursorLine = { link = "CursorLine" },
NeogitCursorLineNr = { link = "CursorLineNr" },
NeogitHunkMergeHeader = { fg = palette.bg2, bg = palette.grey, bold = palette.bold },
Expand Down Expand Up @@ -232,6 +235,7 @@ function M.setup(config)
NeogitStash = { link = "NeogitSubtleText" },
NeogitRebaseDone = { link = "NeogitSubtleText" },
NeogitFold = { fg = "None", bg = "None" },
NeogitFoldColumn = { fg = "None", bg = "None" },
NeogitWinSeparator = { link = "WinSeparator" },
NeogitChangeMuntracked = { link = "NeogitChangeModified" },
NeogitChangeAuntracked = { link = "NeogitChangeAdded" },
Expand Down