diff options
Diffstat (limited to 'src/cmd/pipe.zig')
-rw-r--r-- | src/cmd/pipe.zig | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/cmd/pipe.zig b/src/cmd/pipe.zig index 39bee8c..c3d08e4 100644 --- a/src/cmd/pipe.zig +++ b/src/cmd/pipe.zig @@ -18,7 +18,11 @@ pub const PipeCommand = struct { pub fn eval(pipe: PipeCommand, ctx: CommandContext) !CommandStatus { const execute_command = ctx.execute_command; const allocator = ctx.allocator; - const output_capture = ctx.output_capture; + // Extract output_capture from the output_writer for pipe logic + const output_capture = switch (ctx.output_writer) { + .capture => |capture| capture, + .stdout => null, + }; // Create output capture for the left command var left_output = OutputCapture.init(allocator); |