You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm enjoying your crate, but I hit the wall. Let's say, I would like to execute a command that outputs in threads
all_servers.par_iter().try_for_each(op: |server: &Server| {
cmd!(
sh,
"command with output"
)
what happens that the output interleaves, and I have no way to know which thread outputs what. The only solution is to read the output and prefix it with Id, but that is not possible with your crate, right?
The text was updated successfully, but these errors were encountered:
Yeah, there's nothing built-in for this yet. What should be happening on the level of syscalls here is that each cmd! process should get its stdout/stderr redirected to a pipe (so, two pipes per process). Than, in the host process something should do an epoll loop over these pipes, reading the output and notifiying the user's code that "hey, process #k emitted output foo".
It's not at all clear how to express this functionality in xshell APIs (though it should be possible). A related thing here is that xshell already spawns thread behind user's back, so it won't be inconceivable to do more of that:
Hey,
I'm enjoying your crate, but I hit the wall. Let's say, I would like to execute a command that outputs in threads
what happens that the output interleaves, and I have no way to know which thread outputs what. The only solution is to read the output and prefix it with
Id
, but that is not possible with your crate, right?The text was updated successfully, but these errors were encountered: