| ... | ... | @@ -13,7 +13,7 @@ pub const BlobId = struct { id: Id }; |
| 13 | 13 | pub const TagId = struct { id: Id }; |
| 14 | 14 | |
| 15 | 15 | pub fn version(alloc: std.mem.Allocator) !string { |
| 16 | | const result = try std.ChildProcess.exec(.{ |
| 16 | const result = try std.process.Child.run(.{ |
| 17 | 17 | .allocator = alloc, |
| 18 | 18 | .argv = &.{ "git", "--version" }, |
| 19 | 19 | .max_output_bytes = 1024, |
| ... | ... | @@ -77,7 +77,7 @@ pub fn getObject(alloc: std.mem.Allocator, dir: std.fs.Dir, obj: Id) !string { |
| 77 | 77 | const t = tracer.trace(@src(), " {s}", .{obj}); |
| 78 | 78 | defer t.end(); |
| 79 | 79 | |
| 80 | | const result = try std.ChildProcess.exec(.{ |
| 80 | const result = try std.process.Child.run(.{ |
| 81 | 81 | .allocator = alloc, |
| 82 | 82 | .cwd_dir = dir, |
| 83 | 83 | .argv = &.{ "git", "cat-file", "-p", obj }, |
| ... | ... | @@ -95,7 +95,7 @@ pub fn getObjectSize(alloc: std.mem.Allocator, dir: std.fs.Dir, obj: Id) !u64 { |
| 95 | 95 | const t = tracer.trace(@src(), " {s}", .{obj}); |
| 96 | 96 | defer t.end(); |
| 97 | 97 | |
| 98 | | const result = try std.ChildProcess.exec(.{ |
| 98 | const result = try std.process.Child.run(.{ |
| 99 | 99 | .allocator = alloc, |
| 100 | 100 | .cwd_dir = dir, |
| 101 | 101 | .argv = &.{ "git", "cat-file", "-s", obj }, |
| ... | ... | @@ -111,7 +111,7 @@ pub fn isType(alloc: std.mem.Allocator, dir: std.fs.Dir, maybeobj: Id, typ: Tree |
| 111 | 111 | const t = tracer.trace(@src(), " {s} = {s} ?", .{ maybeobj, @tagName(typ) }); |
| 112 | 112 | defer t.end(); |
| 113 | 113 | |
| 114 | | const result = try std.ChildProcess.exec(.{ |
| 114 | const result = try std.process.Child.run(.{ |
| 115 | 115 | .allocator = alloc, |
| 116 | 116 | .cwd_dir = dir, |
| 117 | 117 | .argv = &.{ "git", "cat-file", "-t", maybeobj }, |
| ... | ... | @@ -128,7 +128,7 @@ pub fn getType(alloc: std.mem.Allocator, dir: std.fs.Dir, obj: Id) !Tree.Object. |
| 128 | 128 | const t = tracer.trace(@src(), " {s}", .{obj}); |
| 129 | 129 | defer t.end(); |
| 130 | 130 | |
| 131 | | const result = try std.ChildProcess.exec(.{ |
| 131 | const result = try std.process.Child.run(.{ |
| 132 | 132 | .allocator = alloc, |
| 133 | 133 | .cwd_dir = dir, |
| 134 | 134 | .argv = &.{ "git", "cat-file", "-t", obj }, |
| ... | ... | @@ -147,7 +147,7 @@ pub fn revList(alloc: std.mem.Allocator, dir: std.fs.Dir, comptime count: u31, f |
| 147 | 147 | const t = tracer.trace(@src(), "({d}) {s} -- {s}", .{ count, from.id, sub_path }); |
| 148 | 148 | defer t.end(); |
| 149 | 149 | |
| 150 | | const result = try std.ChildProcess.exec(.{ |
| 150 | const result = try std.process.Child.run(.{ |
| 151 | 151 | .allocator = alloc, |
| 152 | 152 | .cwd_dir = dir, |
| 153 | 153 | .argv = &.{ |
| ... | ... | @@ -389,7 +389,7 @@ pub fn getTreeDiff(alloc: std.mem.Allocator, dir: std.fs.Dir, commitid: CommitId |
| 389 | 389 | defer t.end(); |
| 390 | 390 | |
| 391 | 391 | if (parentid == null) { |
| 392 | | const result = try std.ChildProcess.exec(.{ |
| 392 | const result = try std.process.Child.run(.{ |
| 393 | 393 | .allocator = alloc, |
| 394 | 394 | .cwd_dir = dir, |
| 395 | 395 | // 4b825dc642cb6eb9a060e54bf8d69288fbee4904 is a hardcode for the empty tree in git sha1 |
| ... | ... | @@ -400,7 +400,7 @@ pub fn getTreeDiff(alloc: std.mem.Allocator, dir: std.fs.Dir, commitid: CommitId |
| 400 | 400 | std.debug.assert(result.term == .Exited and result.term.Exited == 0); |
| 401 | 401 | return std.mem.trim(u8, result.stdout, "\n"); |
| 402 | 402 | } |
| 403 | | const result = try std.ChildProcess.exec(.{ |
| 403 | const result = try std.process.Child.run(.{ |
| 404 | 404 | .allocator = alloc, |
| 405 | 405 | .cwd_dir = dir, |
| 406 | 406 | .argv = &.{ "git", "diff-tree", "-p", "--raw", parentid.?.id, commitid.id }, |
| ... | ... | @@ -657,7 +657,7 @@ pub fn getBranches(alloc: std.mem.Allocator, dir: std.fs.Dir) ![]const Ref { |
| 657 | 657 | const t = tracer.trace(@src(), "", .{}); |
| 658 | 658 | defer t.end(); |
| 659 | 659 | |
| 660 | | const result = try std.ChildProcess.exec(.{ |
| 660 | const result = try std.process.Child.run(.{ |
| 661 | 661 | .allocator = alloc, |
| 662 | 662 | .cwd_dir = dir, |
| 663 | 663 | .argv = &.{ "git", "show-ref", "--heads" }, |
| ... | ... | @@ -687,7 +687,7 @@ pub fn getTags(alloc: std.mem.Allocator, dir: std.fs.Dir) ![]const Ref { |
| 687 | 687 | // a450a23e318c5a8fcba5a52c8fdc2e23584650b3 refs/tags/1.2.5^{} |
| 688 | 688 | // 71264720050572b7bad24532ff39951f47d9296a refs/tags/15.3.1 |
| 689 | 689 | // 7dfd3948a9095f0253bfba60fed52895ffbf84bb refs/tags/15.3.2 |
| 690 | | const result = try std.ChildProcess.exec(.{ |
| 690 | const result = try std.process.Child.run(.{ |
| 691 | 691 | .allocator = alloc, |
| 692 | 692 | .cwd_dir = dir, |
| 693 | 693 | .argv = &.{ "git", "show-ref", "--tags", "--dereference" }, |