mirror of
https://github.com/Cian-H/my_nvim_config.git
synced 2025-12-22 20:21:57 +00:00
Updated gitsigns bindings
This commit is contained in:
@@ -45,7 +45,7 @@ return {
|
|||||||
{
|
{
|
||||||
"<leader>gb",
|
"<leader>gb",
|
||||||
function()
|
function()
|
||||||
package.loaded.gitsigns.blame_line()
|
require("gitsigns").blame_line()
|
||||||
end,
|
end,
|
||||||
desc = "[G]it [B]lame Line",
|
desc = "[G]it [B]lame Line",
|
||||||
mode = "n",
|
mode = "n",
|
||||||
@@ -54,12 +54,10 @@ return {
|
|||||||
"]c",
|
"]c",
|
||||||
function()
|
function()
|
||||||
if vim.wo.diff then
|
if vim.wo.diff then
|
||||||
return "]c"
|
vim.cmd.normal({ "]c", bang = true })
|
||||||
|
else
|
||||||
|
require("gitsigns").nav_hunk("next")
|
||||||
end
|
end
|
||||||
vim.schedule(function()
|
|
||||||
require("gitsigns").next_hunk()
|
|
||||||
end)
|
|
||||||
return "<Ignore>"
|
|
||||||
end,
|
end,
|
||||||
desc = "Next Hunk",
|
desc = "Next Hunk",
|
||||||
mode = "n",
|
mode = "n",
|
||||||
@@ -69,12 +67,10 @@ return {
|
|||||||
"[c",
|
"[c",
|
||||||
function()
|
function()
|
||||||
if vim.wo.diff then
|
if vim.wo.diff then
|
||||||
return "[c"
|
vim.cmd.normal({ "[c", bang = true })
|
||||||
|
else
|
||||||
|
require("gitsigns").nav_hunk("prev")
|
||||||
end
|
end
|
||||||
vim.schedule(function()
|
|
||||||
require("gitsigns").prev_hunk()
|
|
||||||
end)
|
|
||||||
return "<Ignore>"
|
|
||||||
end,
|
end,
|
||||||
desc = "Previous Hunk",
|
desc = "Previous Hunk",
|
||||||
mode = "n",
|
mode = "n",
|
||||||
|
|||||||
@@ -58,6 +58,7 @@ return { -- General programming utilities go here
|
|||||||
},
|
},
|
||||||
})
|
})
|
||||||
end,
|
end,
|
||||||
|
keys = require("config.keys").gitsigns,
|
||||||
},
|
},
|
||||||
{ -- Oil is a very nice buffer-based filetree editor
|
{ -- Oil is a very nice buffer-based filetree editor
|
||||||
"stevearc/oil.nvim",
|
"stevearc/oil.nvim",
|
||||||
|
|||||||
Reference in New Issue
Block a user