can be adapted to Unix:
Any sufficiently complicated Perl, Python, Ruby, Lua, etc script contains an ad hoc, informally-specified, bug-ridden, slow implementation of half of Unix.
And I don't mean the all of the "system" calls. I mean: concurrency, fault tolerance, data persistence, configuration and scalability.
It may be ugly, but combine ksh93/bash, awk, bc, etc (whatever you find on a standard Unix/Linux distro) and you'll find an analog to the features offered by the above mentioned languages. This does not include "abstractions" such as fancy data structures and other syntactical sugar. And, of course, fork/exec isn't going to beat a function call.
However, (and this will be the subject of the next post), Unix under control of advanced shell (such as ksh93 or bash) can have the following capabilities (at least!):
- Coroutines (Co-processes in ksh93 or recent Bash)
- Communicating Sequential Processes (CSP) via named pipes and co-processes
- Dataflow processing (pipes)
- Arbitrary precision math (bc or other calculator)
- Reuse (command line apps)
- File (database) support (ls, awk, find, grep, sqlite command line, etc)
- List processing (command line args + ksh93/bash)
- Functions/apps as first class objects