Skip to content

Commit 431fa9a

Browse files
committed
add git related plugins
1 parent beb60ef commit 431fa9a

File tree

2 files changed

+25
-3
lines changed

2 files changed

+25
-3
lines changed

init.lua

Lines changed: 22 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -232,6 +232,7 @@ require('lazy').setup({
232232
-- NOTE: Plugins can be added with a link (or for a github repo: 'owner/repo' link).
233233
'tpope/vim-sleuth', -- Detect tabstop and shiftwidth automatically
234234
'github/copilot.vim', -- GitHub Copilot
235+
'tpope/vim-fugitive', -- Git commands in nvim
235236

236237
-- NOTE: Plugins can also be added by using a table,
237238
-- with the first argument being the link and the following
@@ -446,6 +447,25 @@ require('lazy').setup({
446447
end,
447448
},
448449

450+
-- Git Blame Plugin
451+
{
452+
'f-person/git-blame.nvim',
453+
-- load the plugin at startup
454+
event = 'VeryLazy',
455+
-- Because of the keys part, you will be lazy loading this plugin.
456+
-- The plugin will only load once one of the keys is used.
457+
-- If you want to load the plugin at startup, add something like event = "VeryLazy",
458+
-- or lazy = false. One of both options will work.
459+
opts = {
460+
-- your configuration comes here
461+
-- for example
462+
enabled = true, -- if you want to enable the plugin
463+
message_template = ' <author> • <date> • <summary> ', -- template for the blame message, check the Message template section for more options
464+
date_format = '%Y-%m-%d %H:%M', -- template for the date, check Date format section for more options
465+
virtual_text_column = 1, -- virtual text start column, check Start virtual text at column section for more options
466+
},
467+
},
468+
449469
-- LSP Plugins
450470
{
451471
-- `lazydev` configures Lua LSP for your Neovim config, runtime and plugins
@@ -556,7 +576,8 @@ require('lazy').setup({
556576
-- the definition of its *type*, not where it was *defined*.
557577
map('grt', require('telescope.builtin').lsp_type_definitions, '[G]oto [T]ype Definition')
558578

559-
map('K', vim.lsp.buf.hover, 'Hover Documentation')
579+
-- Show the signature of the symbol under your cursor.
580+
map('gh', vim.lsp.buf.hover, 'Hover Documentation')
560581

561582
-- This function resolves a difference between neovim nightly (version 0.11) and stable (version 0.10)
562583
---@param client vim.lsp.Client

lazy-lock.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,21 +4,22 @@
44
"conform.nvim": { "branch": "master", "commit": "372fc521f8421b7830ea6db4d6ea3bae1c77548c" },
55
"copilot.vim": { "branch": "release", "commit": "8d1e0f86d8aaa64070c080589bc2a516beb4024f" },
66
"fidget.nvim": { "branch": "main", "commit": "d9ba6b7bfe29b3119a610892af67602641da778e" },
7-
"gitsigns.nvim": { "branch": "main", "commit": "b79047e81f645875e500b4f433d8133bc421446c" },
7+
"gitsigns.nvim": { "branch": "main", "commit": "ee7e50dfbdf49e3acfa416fd3ad3abbdb658582c" },
88
"lazy.nvim": { "branch": "main", "commit": "6c3bda4aca61a13a9c63f1c1d1b16b9d3be90d7a" },
99
"lazydev.nvim": { "branch": "main", "commit": "2367a6c0a01eb9edb0464731cc0fb61ed9ab9d2c" },
1010
"mason-lspconfig.nvim": { "branch": "main", "commit": "1a31f824b9cd5bc6f342fc29e9a53b60d74af245" },
1111
"mason-tool-installer.nvim": { "branch": "main", "commit": "1255518cb067e038a4755f5cb3e980f79b6ab89c" },
1212
"mason.nvim": { "branch": "main", "commit": "fc98833b6da5de5a9c5b1446ac541577059555be" },
1313
"mini.nvim": { "branch": "main", "commit": "05975f387906211745d0aaf996eb7ad3c91b193d" },
14-
"nvim-lspconfig": { "branch": "master", "commit": "5af60bbb835d5b6efdc64cdff2a5b27cde4120de" },
14+
"nvim-lspconfig": { "branch": "master", "commit": "8b0f47d851ee5343d38fe194a06ad16b9b9bd086" },
1515
"nvim-treesitter": { "branch": "master", "commit": "684eeac91ed8e297685a97ef70031d19ac1de25a" },
1616
"plenary.nvim": { "branch": "master", "commit": "857c5ac632080dba10aae49dba902ce3abf91b35" },
1717
"telescope-fzf-native.nvim": { "branch": "main", "commit": "1f08ed60cafc8f6168b72b80be2b2ea149813e55" },
1818
"telescope-ui-select.nvim": { "branch": "master", "commit": "6e51d7da30bd139a6950adf2a47fda6df9fa06d2" },
1919
"telescope.nvim": { "branch": "master", "commit": "a4ed82509cecc56df1c7138920a1aeaf246c0ac5" },
2020
"todo-comments.nvim": { "branch": "main", "commit": "304a8d204ee787d2544d8bc23cd38d2f929e7cc5" },
2121
"tokyonight.nvim": { "branch": "main", "commit": "057ef5d260c1931f1dffd0f052c685dcd14100a3" },
22+
"vim-fugitive": { "branch": "master", "commit": "4a745ea72fa93bb15dd077109afbb3d1809383f2" },
2223
"vim-sleuth": { "branch": "master", "commit": "be69bff86754b1aa5adcbb527d7fcd1635a84080" },
2324
"which-key.nvim": { "branch": "main", "commit": "370ec46f710e058c9c1646273e6b225acf47cbed" }
2425
}

0 commit comments

Comments
 (0)