scsh is the scheme shell, a variant of scheme 48, running on all major Unix platforms including AIX, Cygwin, Linux, FreeBSD, HP-UX, Irix, Mac OS X?, Solaris, and some others. Rather than providing an interactive command shell, like bash, csh, etc., scsh is optimized at this time for shellscripting. The software is released under a BSD license.
scsh has two main components: a process notation for running programs and setting up pipelines? and redirections, 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. Moreover, scsh provides an awk? facility for pattern-directed computation over streams? of records, a rich facility for matching regular expression patterns in strings, event-based interrupt handling, user-level threads, a futuristic module system, and an interactive environment. Scsh comes with extensive documentation describing these and other features.
For instance, the unix pipelined shell command:
gunzip < paper.tex.gz | detex | spell | lpr -Ppulp &
would be written in scsh as
(& (| (gunzip) (detex) (spell) (lpr -Ppulp)) ; background a pipeline
(< paper.tex.gz)) ; with this redirection
After playing with scsh for a while, you'll eventually be exposed to Olin Shivers, scsh's author.
Some complementary CL packages are cl-ppcre, nregex?, regex-CLAWK-lexer, PCRE. There is also a Regular expression page on Cliki. Although scsh is Scheme and not Common Lisp, it presents a good example of how to play nice with unix. The Lisp Universal SHell (LUSH) is another uncommon Lisp trying to do the same. It would be a nice project to provide similar interfaces for ECL or GCL, mainly because SCSH lacks 'real' macros.
This page is linked from: Cut and shut
CLiki pages can be edited by anyone at any time. Imagine a fearsomely comprehensive disclaimer of liability. Now fear, comprehensively