Coprocess Language Support - oilshell/oil GitHub Wiki

Back to Coprocess Protocol V2

  • C and C++ have everything we need -- dup2(), recvmsg()
  • Python
    • Python 2 has dup2() but not recvmsg()
    • Python 3 has both
  • R: probably need a C extension for dup2()
  • JVM: Jakub D did an experiment in Clojure (see #shell-completion thread on Zulip "Closh"). System.setOut and System.setErr seem to work.
    • The JVM will prints its stack traces there.
  • node.js: maybe monkey patch process.stdout and process.stderr?

TODO

  • Go -- is it OK to use syscalls?
  • Rust should be able to call libc ?
  • Ruby, Perl, PHP, etc.

Ruby can start slowly and there are many command line tools written with it, so this is a good use case.