Skip to content

LazyGit Extra

git.lazygit opens LazyGit inside a Snacks float and wires a discoverable Blak keymap. It requires the lazygit executable to be available in $PATH.

Enable it

-- ~/.config/blak/lua/blak/user.lua
return {
extras = {
enabled = {
"git.lazygit",
},
},
}

Or enable it interactively:

:BlakExtras enable git.lazygit

What it adds

SurfaceContribution
Snackslazygit.enabled = true
Keymap<leader>gg opens LazyGit
External binarylazygit in $PATH

The keymap appears in :BlakKeys.

Configure LazyGit integration

Snacks LazyGit options go under snacks.lazygit:

return {
extras = {
enabled = { "git.lazygit" },
},
snacks = {
lazygit = {
configure = true,
config = {
gui = {
nerdFontsVersion = "3",
},
},
win = {
width = 0.95,
height = 0.95,
},
},
},
}

If you maintain your own LazyGit config and do not want Snacks to write its generated integration config, turn off configure:

return {
extras = {
enabled = { "git.lazygit" },
},
snacks = {
lazygit = {
configure = false,
},
},
}

Use it

<leader>gg

Or call Snacks directly:

:lua require("snacks").lazygit()

Run :checkhealth snacks or :BlakDoctor if the binary is not found.