✨ feat(nvim): neogit overhaul and diffview integration
This commit is contained in:
parent
3cbfb5064c
commit
5634089788
2 changed files with 30 additions and 10 deletions
|
@ -4,7 +4,7 @@ return {
|
||||||
{
|
{
|
||||||
"sindrets/diffview.nvim",
|
"sindrets/diffview.nvim",
|
||||||
keys = {
|
keys = {
|
||||||
{ "<leader>gY", "<cmd>DiffviewFileHistory<CR>", desc = "Repo History (Diff)" },
|
{ "<leader>gD", "<cmd>DiffviewFileHistory<CR>", desc = "Diff Repo" },
|
||||||
{ "<leader>gd", "<cmd>DiffviewOpen<CR>", desc = "Diff View" },
|
{ "<leader>gd", "<cmd>DiffviewOpen<CR>", desc = "Diff View" },
|
||||||
},
|
},
|
||||||
opts = function(_, opts)
|
opts = function(_, opts)
|
||||||
|
@ -46,6 +46,15 @@ return {
|
||||||
}
|
}
|
||||||
end,
|
end,
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"NeogitOrg/neogit",
|
||||||
|
optional = true,
|
||||||
|
opts = {
|
||||||
|
integrations = {
|
||||||
|
diffview = true,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"folke/which-key.nvim",
|
"folke/which-key.nvim",
|
||||||
opts = {
|
opts = {
|
||||||
|
|
|
@ -1,13 +1,24 @@
|
||||||
|
local prefix = "<leader>gn"
|
||||||
|
|
||||||
return {
|
return {
|
||||||
|
{
|
||||||
"NeogitOrg/neogit",
|
"NeogitOrg/neogit",
|
||||||
dependencies = {
|
cmd = "Neogit",
|
||||||
"nvim-lua/plenary.nvim",
|
|
||||||
{ "sindrets/diffview.nvim", optional = true },
|
|
||||||
"nvim-telescope/telescope.nvim",
|
|
||||||
},
|
|
||||||
cmd = { "Neogit" },
|
|
||||||
opts = {},
|
opts = {},
|
||||||
keys = {
|
keys = {
|
||||||
{ "<leader>gn", "<cmd>Neogit<cr>", desc = "Neogit" },
|
{ prefix .. "n", "<cmd>Neogit<cr>", desc = "Neogit (Root Dir)" },
|
||||||
|
{ prefix .. "c", "<cmd>Neogit commit<cr>", desc = "Commit" },
|
||||||
|
{ prefix .. "p", "<cmd>Neogit pull<cr>", desc = "Pull" },
|
||||||
|
{ prefix .. "P", "<cmd>Neogit push<cr>", desc = "Push" },
|
||||||
|
{ prefix .. "f", "<cmd>Neogit fetch<cr>", desc = "Fetch" },
|
||||||
|
},
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"folke/which-key.nvim",
|
||||||
|
opts = {
|
||||||
|
spec = {
|
||||||
|
{ prefix, group = "neogit", icon = " " },
|
||||||
|
},
|
||||||
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue