This package exports an implementation of the COMMON-LISP ED function
following the user manual of ed(1).

ed(1) in COMMON-LISP.

Real men do it with magnets.  ed is for girly men.

This is a clone of the unix ed(1) editor written in pure Common-Lisp.
Since Common-Lisp does not define any process management functions,
all !command forms are taken as Lisp forms instead of sh(1) commands.
These forms are executed within a (LAMBDA (*INPUT*) command) with
the *INPUT* argument bound to a mutable list of inmutable input strings,
one per line.  The result of the returning form in command must be
a list of string, the list of resulting lines to be inserted into the
buffer or to be printed on the terminal.

For the rest, the aim is to be 100% user-interface compatible with ed(1).

Ed, man! !man ed: <>

Can you imagine that some Common-Lisp implementations DON'T provide
any editor (in conformity with the Common-Lisp specifications)?
Not complete (waiting for a REGEXP package). But otherwise
functional enough. 


    Copyright Pascal J. Bourguignon 2003 - 2015

    This program is free software: you can redistribute it and/or modify
    it under the terms of the GNU Affero General Public License as published by
    the Free Software Foundation, either version 3 of the License, or
    (at your option) any later version.
    This program is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    GNU Affero General Public License for more details.
    You should have received a copy of the GNU Affero General Public License
    along with this program.
    If not, see <>

(ed &optional x)
DO:  Invokes the ed(1)-like editor.
X:   NIL, a pathname, a string, or a function name. The default is NIL.