1
0
mirror of https://github.com/jdhao/nvim-config.git synced 2025-06-08 14:14:33 +02:00

Merge pull request #111 from jdhao/gitsign

enable word diff for gitsigns.nvim
This commit is contained in:
jdhao 2022-09-24 15:37:15 +08:00 committed by GitHub
commit 830297a973
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -8,6 +8,7 @@ gs.setup {
topdelete = { hl = "GitSignsDelete", text = "", numhl = "GitSignsDeleteNr", linehl = "GitSignsDeleteLn" },
changedelete = { hl = "GitSignsChange", text = "", numhl = "GitSignsChangeNr", linehl = "GitSignsChangeLn" },
},
word_diff = true,
on_attach = function(bufnr)
local function map(mode, l, r, opts)
opts = opts or {}
@ -43,3 +44,12 @@ gs.setup {
end)
end,
}
vim.api.nvim_create_autocmd('ColorScheme', {
pattern = "*",
callback = function()
vim.cmd [[
hi GitSignsChangeInline guibg=fg guifg=bg
]]
end
})