This repository has been archived on 2025-01-07. You can view files and clone it, but cannot push or open issues or pull requests.
opdavies.nvim/after/plugin/git.lua

31 lines
441 B
Lua
Raw Normal View History

local status_ok, neogit = pcall(require, "neogit")
if not status_ok then
return
end
neogit.setup {
disable_commit_confirmation = true,
}
local nmap = require("opdavies.keymap").nmap
nmap {
"<leader>gc",
function()
neogit.open { "commit" }
end,
}
nmap {
"<leader>gl",
function()
neogit.open { "log" }
end,
}
nmap {
"<leader>gp",
function()
neogit.open { "push" }
end,
}
nmap { "<leader>gs", neogit.open }