mesalock-linux / mesabox

A collection of core system utilities written in Rust for Unix-like systems (and now Windows)
BSD 3-Clause "New" or "Revised" License
137 stars 19 forks source link

Implement piping #14

Closed Arcterus closed 6 years ago

Arcterus commented 6 years ago

The relevant sections are mostly in src/posix/sh/command.rs. ~We can't just use ChildStdin/ChildStdout/ChildStderr because we need to support other file descriptors as well, so we need to create the pipes manually using nix.~

EDIT: dunno why I wrote the above, but ChildStdout should be passed into the next command as its stdin.

Arcterus commented 6 years ago

This requires some sort of method to spawn commands without waiting for them to finish (as they need to be started at the same time).

Arcterus commented 6 years ago

For the most part, this was resolved in 295ba2d3dab26878d3a2d7f9da31cf103ce31544.