replace vim-fugitive with neogit and diffview

This commit is contained in:
Fábio André Damas 2025-03-31 09:21:32 +01:00
parent 39820d8048
commit a0af7d34f9
5 changed files with 21 additions and 4 deletions

3
lua/plugins/diffview.lua Normal file
View file

@ -0,0 +1,3 @@
return {
'sindrets/diffview.nvim'
}

View file

@ -9,6 +9,11 @@ local format_on_save = function(client, bufnr)
group = augroup,
buffer = bufnr,
callback = function()
-- prevents format from being included in the undo history
-- this way the cursor doesn't jump around the file when
-- undoing
vim.cmd("silent! undojoin")
vim.lsp.buf.format({
bufnr = bufnr,
async = false,

7
lua/plugins/neogit.lua Normal file
View file

@ -0,0 +1,7 @@
return {
"NeogitOrg/neogit",
dependencies = {
"nvim-lua/plenary.nvim",
},
config = true
}

View file

@ -1,3 +1,4 @@
return {
"tpope/vim-fugitive"
}
return {}
-- return {
-- "tpope/vim-fugitive"
-- }