nvim: Diff against branch
This commit is contained in:
@@ -43,6 +43,17 @@ return {
|
|||||||
gs.diffthis("~")
|
gs.diffthis("~")
|
||||||
end, "Diff this ~")
|
end, "Diff this ~")
|
||||||
|
|
||||||
|
map("n", "<leader>hc", function()
|
||||||
|
Snacks.picker.git_branches({
|
||||||
|
confirm = function(picker, item)
|
||||||
|
picker:close()
|
||||||
|
if item and item.branch then
|
||||||
|
gs.diffthis(item.branch)
|
||||||
|
end
|
||||||
|
end,
|
||||||
|
})
|
||||||
|
end, "Diff against branch")
|
||||||
|
|
||||||
-- Text object
|
-- Text object
|
||||||
map({ "o", "x" }, "ih", ":<C-U>Gitsigns select_hunk<CR>", "Gitsigns select hunk")
|
map({ "o", "x" }, "ih", ":<C-U>Gitsigns select_hunk<CR>", "Gitsigns select hunk")
|
||||||
end,
|
end,
|
||||||
|
|||||||
Reference in New Issue
Block a user