4 ms·
If you're adding IPC mechanisms to a shell script, seriously consider if you should be writing it in a lower level language, like python or go or rust...
by ehutch79 5y ago
If you're adding IPC mechanisms to a shell script, seriously consider if you should be writing it in a lower level language, like python or go or rust...
- jhgb 5y agoYou can use it from whatever you want; it's not just for shell scripts. Although why you'd go for a lower level language if you don't have to for some specific reason is beyond me. GUIs specifically have been historically very friendly towards very high level languages - see Tcl/Tk. Also, by your logic, shell scripts should never use pipes; you should always use pipes from Python or Go or Rust. But I suspect that's not how other people usually think.
- ehutch79 5y agoMy experience with anything involving tcl/tk has always been suboptimal. Also, we're specifically talking about shell scripts. I'd argue that if you're implementing an entire protocol into a shell script, yes, you should consider more efficient languages. If you're just dumping data into a pipe like you would to std out, sure that's fine. The key here, at least for me, is complexity. Are you bludgeoning shell scripts into something it wasn't meant for? Is there a better alternative meant to do the thing you're doing?
- jhgb 5y agoWell, if you prefer Python, Perl, or Ruby, you can use those fairly easily.