Cash is a Unix shell that is embedded within Objective Caml. It's a Caml implementation of (an as large as possible subset of) the API of Scsh, the Scheme Shell by Olin Shivers. See the Scsh site.
The Scsh API is designed for writing useful standalone Unix programs and shell scripts (but rather not for interactive command use). It spans a wide range of application, from “script” applications usually handled with perl or sh, to more standard systems applications usually written in C.
It has two main components: a process notation for running programs and setting up pipelines and redirections (not yet implemented in Cash), and a complete syscall library for low-level access to the operating system, i.e. to POSIX, the least common denominator of more or less all Unices, plus widely supported extensions such as symbolic links and BSD sockets.
Cash may be considered as an alternative to the
Unix module; the
Unixessentially targets C level interface, and abstracts the file_descr type;
The Cash user's manual is available here: in dvi form, postscript, or html.
The current version is Cash 0.20, released on the last week of 2002 Aug.
For those who know Scsh, when compared to the full Scsh API, Cash has a large part of the "procedural interface" of Scsh 0.5.3, but no syntax extensions: there's no process notation, no regexp notation, no awk loop. I intend to implement a process notation in a future release. Regexps are delegated to PCRE for now. I have no plan for awk.
What's been added/changed in 0.20:
write_stringand its cousins;
fork_with_pipe_plus(complex connections in pipes);
call_with_input_file, call_with_output_file, call_with_fdes_fn(Scheme compatibility);
run_with_out_channel, run_with_outchan_plus_proc, and
What is still missing in the procedural interface:
If you find a bug (in the doc too), have a contribution, etc., drop a message to Bruno.Verlyck@inria.fr.
To all the authors of Scsh, but especially to Olin Shivers, for his enormous work of design of the API, and making it open source.
Copyright © 2002 INRIA all rights reserved.
Contact the author Bruno.Verlyck@inria.fr