3 ms·
I played around with what I think is a very similar idea a while back: https://github.com/ianb/jsshell https://github.com/ianb/jsshell -- I think the basic arch
by ianb 15y ago
I played around with what I think is a very similar idea a while back: https://github.com/ianb/jsshell https://github.com/ianb/jsshell -- I think the basic architecture is the same, but this is much more advanced; I never really got past the point of displaying all output as literals.
In both cases I think this is really as much a replacement for the shell (e.g., bash) as for the terminal. The truly fundamental verb in a Unix system is executing something with a set of string parameters, an environment, and a cwd, and passing stdin in, with stderr and stdout coming out. That's pretty much everything, so there's a lot of flexibility about how you can present that to a person -- all the stuff like &, if statements, file redirection, shell quoting, etc., is part of the shell UI, it isn't really core to the OS or any of the commands.
There's a lot of graphics and icons in this particular implementation, but IMHO that's not really the important part. Taking out the statefulness of the shell is the more interesting part to me. "cd" seems magic, but it's just setting an internal variable in the shell. Foreground and background processes seem core, but they are just a way of handling the inability for a terminal to handle more than one thing at once. Variable substitution, redirection, backticks... these are all abstractions; and they are useful abstractions, but they might deserve a bit of rethinking.