Skip to content

Commit

Permalink
Git stage hunks
Browse files Browse the repository at this point in the history
  • Loading branch information
BakerNet committed Apr 30, 2024
1 parent 8928e2a commit 0cb8303
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions lua/plugins/git.lua
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,10 @@ return {
{ buffer = bufnr, desc = 'Toggle [G]it Line [B]lame' })
vim.keymap.set('n', '<leader>gu', require('gitsigns').reset_hunk,
{ buffer = bufnr, desc = 'Toggle [G]it [U]ndo (Reset) Hunk' })
vim.keymap.set('n', '<leader>gs', require('gitsigns').stage_hunk,
{ buffer = bufnr, desc = 'Toggle [G]it [S]tage Hunk' })
vim.keymap.set('n', '<leader>gr', require('gitsigns').undo_stage_hunk,
{ buffer = bufnr, desc = 'Toggle [G]it [R]eset (Undo previous) Hunk' })
end
},
{
Expand Down

0 comments on commit 0cb8303

Please sign in to comment.