change neogit command to :Neog

This commit is contained in:
LordMZTE 2023-07-29 10:44:55 +02:00
parent 9a1510a643
commit a02d1ccdff
Signed by: LordMZTE
GPG key ID: B64802DC33A64FF6
2 changed files with 3 additions and 2 deletions

View file

@ -2,4 +2,4 @@
(ngit.setup {})
(vim.api.nvim_create_user_command :Neogit ngit.open {:nargs 0})
(vim.api.nvim_create_user_command :Neog ngit.open {:nargs 0})

View file

@ -7,7 +7,8 @@ pub const c = @cImport({
});
/// Generates a wrapper function with error handling for a lua CFunction
pub fn luaFunc(comptime func: fn (*c.lua_State) anyerror!c_int) c.lua_CFunction {
/// func should be `fn(*c.lua_State) !c_int` ()
pub fn luaFunc(comptime func: anytype) c.lua_CFunction {
return &struct {
fn f(l: ?*c.lua_State) callconv(.C) c_int {
return func(l.?) catch |e| {