$ rlwrap scsh
Welcome to scsh 0.6.7 (R6RS)
Type ,? for help.
> (run (date))
Fri Mar 30 00:10:46 PDT 2012
0
> (run (| (ls) (grep -P ".tar.(gz|lrz)$")))
comments.tar.gz
comments.tar.lrz
pings.tar.lrz
pings0.tar.lrz
pings1.tar.lrz
pings2.tar.lrz
pings3.tar.lrz
0
The 0 is the return value of the program. [One thing that threw me was that -i is read as the complex number that Racket would call 0-1i; you would have to type "-i" with quotes around it, or (lolololololz) -ii if your program handles multiple instances of the same switch fine.]
The author, Olin Shivers, has a paper[1] that describes the process control notation demonstrated above, and an awk-like notation, both written essentially as Scheme macros. (Actually, I think they are Scheme macros.) "Whenever necessary, the user can break out of the special-purpose notation and express complex computations in a general-purpose programming language. The Scheme embedding makes simple things easy, and complex things possible. The standalone little language only provides the former."
Yeah I am aware of scsh; I was thinking of it when I referred to fewer parens :)
Here's wart's equivalent for the first command:
wart> date.
Or
wart> run date.
I want support for infix pipes and redirection operators. No matter how much lisp I use I can't get used to putting the pipe before different commands.
An alternative is to double down on lisp syntax but make the line editing much nicer. As nice as an emacs buffer.