From 6f84a9a1458ff053d6dc7c1a66c1e03deb8e8793 Mon Sep 17 00:00:00 2001 From: Matthias Andreas Benkard Date: Fri, 15 Aug 2025 13:43:22 +0200 Subject: CommandContext: Add execute_command back, properly typed. --- src/eval.zig | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/eval.zig') diff --git a/src/eval.zig b/src/eval.zig index 7bd7da7..17486aa 100644 --- a/src/eval.zig +++ b/src/eval.zig @@ -36,7 +36,7 @@ pub fn executeCommand(command: Command, allocator: Allocator) !CommandStatus { } pub fn executeCommandWithOutput(command: Command, allocator: Allocator, output_capture: ?*OutputCapture, input_source: ?*InputSource) !CommandStatus { - const ctx = CommandContext.init(allocator, output_capture, input_source); + const ctx = CommandContext.init(allocator, output_capture, input_source, executeCommandWithOutput); switch (command) { .Empty => return CommandStatus{ .Code = 0 }, @@ -124,11 +124,11 @@ pub fn executeCommandWithOutput(command: Command, allocator: Allocator, output_c }, .Redirect => |redirect| { - return redirect.eval(ctx, executeCommandWithOutput); + return redirect.eval(ctx); }, .Pipe => |pipe| { - return pipe.eval(ctx, executeCommandWithOutput); + return pipe.eval(ctx); }, } } -- cgit v1.2.1