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
Hello,
Thanks for the great library! I'm new to Gleam, and this seems very useful to program abstractions around shell commands and such.
I'd like to ask, are there any plans for tools to work with stdin? In particular:
Being able to provide a certain string (or bytes) as the full standard input to a program;
Being able to redirect all stdin received by the Gleam program to the input of the program being run (something akin to LetBeStdin);
Being able to pipe a program's stdout to another program's stdin in an efficient manner (could be platform-restricted if needed). This could require a deeper rework (to e.g. use some sort of Process type), but I still think that could be very handy when working with e.g. lots of data in the shell.
Thanks in advance!
The text was updated successfully, but these errors were encountered:
For my thoughts about the future of this library, check #5 (comment)
As for stdin, shellout should already be as transparent as possible about it, meaning it should be possible to pipe stdin to a command already in many cases. In other words, LetBeStdin shouldn't be necessary, but Erlang itself has some limitations with stdin, as I recall. Potentially in the future, I'll provide a NIF (possibly with a number of precompiled binaries available) I've been toying with that has solved my previous frustrations with Erlang.
I'll definitely consider your other suggestions when I start working on shellout v2.0.
For the time being, I think your first and third ideas might be currently doable as, e.g.
Hello,
Thanks for the great library! I'm new to Gleam, and this seems very useful to program abstractions around shell commands and such.
I'd like to ask, are there any plans for tools to work with
stdin
? In particular:stdin
received by the Gleam program to the input of the program being run (something akin toLetBeStdin
);stdout
to another program'sstdin
in an efficient manner (could be platform-restricted if needed). This could require a deeper rework (to e.g. use some sort ofProcess
type), but I still think that could be very handy when working with e.g. lots of data in the shell.Thanks in advance!
The text was updated successfully, but these errors were encountered: