Update lazygit

This commit is contained in:
Karolis Arbaciauskas 2025-01-01 20:22:33 +02:00
parent c0e189e56f
commit d625f9c8cb
No known key found for this signature in database
3 changed files with 30 additions and 40 deletions

View File

@ -995,7 +995,6 @@ require('lazy').setup({
require 'kickstart.plugins.indent_line',
require 'kickstart.plugins.lint',
require 'kickstart.plugins.autopairs',
-- require 'kickstart.plugins.neo-tree',
require 'kickstart.plugins.gitsigns', -- adds gitsigns recommend keymaps
-- NOTE: The import below can automatically add your own plugins, configuration, etc from `lua/custom/plugins/*.lua`

View File

@ -1,20 +1,36 @@
return {
'kdheepak/lazygit.nvim',
lazy = true,
cmd = {
'LazyGit',
'LazyGitConfig',
'LazyGitCurrentFile',
'LazyGitFilter',
'LazyGitFilterCurrentFile',
},
dependencies = {
'nvim-lua/plenary.nvim',
'folke/snacks.nvim',
---@diagnostic disable-next-line: undefined-doc-name
---@type snacks.Config
opts = {
lazygit = {
-- your lazygit configuration comes here
-- or leave it empty to use the default settings
-- refer to the configuration section below
},
},
keys = {
{ '<leader>gg', '<cmd>LazyGit<cr>', desc = 'Lazygit (Root Dir)' },
{ '<leader>gf', '<cmd>LazyGitFilterCurrentFile<cr>', desc = 'Lazygit Current File History' },
{ '<leader>gl', '<cmd>LazyGitFilter<cr>', desc = 'Lazygit log' },
{
'<leader>gg',
function()
Snacks.lazygit { cwd = vim.fn.getcwd() }
end,
{ desc = 'Lazygit (Root Dir)' },
},
{
'<leader>gf',
function()
Snacks.lazygit.log_file()
end,
{ desc = 'Lazygit Current File History' },
},
{
'<leader>gl',
function()
Snacks.lazygit.log { cwd = vim.fn.getcwd() }
end,
{ desc = 'Lazygit Log' },
},
{ '<leader>gb', '<cmd>Gitsigns blame<cr>', desc = 'Git blame' },
{ '<leader>gs', '<cmd>Telescope git_status<CR>', desc = 'Git Status' },
},

View File

@ -1,25 +0,0 @@
-- Neo-tree is a Neovim plugin to browse the file system
-- https://github.com/nvim-neo-tree/neo-tree.nvim
return {
'nvim-neo-tree/neo-tree.nvim',
version = '*',
dependencies = {
'nvim-lua/plenary.nvim',
'nvim-tree/nvim-web-devicons', -- not strictly required, but recommended
'MunifTanjim/nui.nvim',
},
cmd = 'Neotree',
keys = {
{ '\\', ':Neotree reveal<CR>', desc = 'NeoTree reveal', silent = true },
},
opts = {
filesystem = {
window = {
mappings = {
['\\'] = 'close_window',
},
},
},
},
}