diff --git a/git.zig b/git.zig index ba168662533a983a84549e3ecc771cf40746c0a1..10b61ecc4dfe188290148710b3d1eafcec3e8ac7 100644 --- a/git.zig +++ b/git.zig @@ -29,7 +29,7 @@ pub fn getObject(alloc: std.mem.Allocator, dir: std.fs.Dir, obj: Id) !string { .cwd_dir = dir, .argv = &.{ "git", "cat-file", "-p", obj }, }); - return result.stdout; + return std.mem.trimRight(u8, result.stdout, "\n"); } pub fn parseCommit(alloc: std.mem.Allocator, commitfile: string) !Commit {