mirror of
https://github.com/pojokcodeid/nvim-lazy.git
synced 2025-06-22 00:49:01 +02:00
75 lines
1.9 KiB
Lua
75 lines
1.9 KiB
Lua
local icons = vim.g.pcode_icons
|
|
return {
|
|
"lewis6991/gitsigns.nvim",
|
|
lazy = true,
|
|
enabled = vim.fn.executable("git") == 1,
|
|
ft = "gitcommit",
|
|
event = "BufRead",
|
|
opts = {
|
|
signs = {
|
|
add = {
|
|
hl = "GitSignsAdd",
|
|
text = icons.ui.BoldLineLeft,
|
|
numhl = "GitSignsAddNr",
|
|
linehl = "GitSignsAddLn",
|
|
},
|
|
change = {
|
|
hl = "GitSignsChange",
|
|
text = icons.ui.BoldLineLeft,
|
|
numhl = "GitSignsChangeNr",
|
|
linehl = "GitSignsChangeLn",
|
|
},
|
|
delete = {
|
|
hl = "GitSignsDelete",
|
|
text = icons.ui.Triangle,
|
|
numhl = "GitSignsDeleteNr",
|
|
linehl = "GitSignsDeleteLn",
|
|
},
|
|
topdelete = {
|
|
hl = "GitSignsDelete",
|
|
text = icons.ui.Triangle,
|
|
numhl = "GitSignsDeleteNr",
|
|
linehl = "GitSignsDeleteLn",
|
|
},
|
|
changedelete = {
|
|
hl = "GitSignsChange",
|
|
text = icons.ui.BoldLineLeft,
|
|
numhl = "GitSignsChangeNr",
|
|
linehl = "GitSignsChangeLn",
|
|
},
|
|
},
|
|
signcolumn = true,
|
|
numhl = false,
|
|
linehl = false,
|
|
word_diff = false,
|
|
watch_gitdir = {
|
|
interval = 1000,
|
|
follow_files = true,
|
|
},
|
|
attach_to_untracked = true,
|
|
current_line_blame = false, -- Toggle with `:Gitsigns toggle_current_line_blame`
|
|
current_line_blame_opts = {
|
|
virt_text = true,
|
|
virt_text_pos = "eol", -- 'eol' | 'overlay' | 'right_align'
|
|
delay = 1000,
|
|
ignore_whitespace = false,
|
|
},
|
|
current_line_blame_formatter = "<author>, <author_time:%Y-%m-%d> - <summary>",
|
|
sign_priority = 6,
|
|
status_formatter = nil, -- Use default
|
|
update_debounce = 200,
|
|
max_file_length = 40000,
|
|
preview_config = {
|
|
-- Options passed to nvim_open_win
|
|
border = "rounded",
|
|
style = "minimal",
|
|
relative = "cursor",
|
|
row = 0,
|
|
col = 1,
|
|
},
|
|
yadm = { enable = false },
|
|
},
|
|
config = function(_, opts)
|
|
require("gitsigns").setup(opts)
|
|
end,
|
|
}
|