move ed/tests files to regress/bin/ed, where they are used
authorderaadt <deraadt@openbsd.org>
Mon, 19 Aug 2024 01:43:23 +0000 (01:43 +0000)
committerderaadt <deraadt@openbsd.org>
Mon, 19 Aug 2024 01:43:23 +0000 (01:43 +0000)
372 files changed:
bin/ed/test/Makefile [deleted file]
bin/ed/test/README [deleted file]
bin/ed/test/TODO [deleted file]
bin/ed/test/a.d [deleted file]
bin/ed/test/a.r [deleted file]
bin/ed/test/a.t [deleted file]
bin/ed/test/a1.err [deleted file]
bin/ed/test/a2.err [deleted file]
bin/ed/test/addr.d [deleted file]
bin/ed/test/addr.r [deleted file]
bin/ed/test/addr.t [deleted file]
bin/ed/test/addr1.err [deleted file]
bin/ed/test/addr2.err [deleted file]
bin/ed/test/ascii.d [deleted file]
bin/ed/test/ascii.r [deleted file]
bin/ed/test/ascii.t [deleted file]
bin/ed/test/bang1.d [deleted file]
bin/ed/test/bang1.err [deleted file]
bin/ed/test/bang1.r [deleted file]
bin/ed/test/bang1.t [deleted file]
bin/ed/test/bang2.err [deleted file]
bin/ed/test/c.d [deleted file]
bin/ed/test/c.r [deleted file]
bin/ed/test/c.t [deleted file]
bin/ed/test/c1.err [deleted file]
bin/ed/test/c2.err [deleted file]
bin/ed/test/ckscripts.sh [deleted file]
bin/ed/test/d.d [deleted file]
bin/ed/test/d.err [deleted file]
bin/ed/test/d.r [deleted file]
bin/ed/test/d.t [deleted file]
bin/ed/test/d0.d [deleted file]
bin/ed/test/d0.r [deleted file]
bin/ed/test/d0.t [deleted file]
bin/ed/test/d1.d [deleted file]
bin/ed/test/d1.r [deleted file]
bin/ed/test/d1.t [deleted file]
bin/ed/test/d2.d [deleted file]
bin/ed/test/d2.r [deleted file]
bin/ed/test/d2.t [deleted file]
bin/ed/test/d3.d [deleted file]
bin/ed/test/d3.r [deleted file]
bin/ed/test/d3.t [deleted file]
bin/ed/test/d4.d [deleted file]
bin/ed/test/d4.r [deleted file]
bin/ed/test/d4.t [deleted file]
bin/ed/test/d5.d [deleted file]
bin/ed/test/d5.r [deleted file]
bin/ed/test/d5.t [deleted file]
bin/ed/test/e1.d [deleted file]
bin/ed/test/e1.err [deleted file]
bin/ed/test/e1.r [deleted file]
bin/ed/test/e1.t [deleted file]
bin/ed/test/e2.d [deleted file]
bin/ed/test/e2.err [deleted file]
bin/ed/test/e2.r [deleted file]
bin/ed/test/e2.t [deleted file]
bin/ed/test/e3.d [deleted file]
bin/ed/test/e3.err [deleted file]
bin/ed/test/e3.r [deleted file]
bin/ed/test/e3.t [deleted file]
bin/ed/test/e4.d [deleted file]
bin/ed/test/e4.r [deleted file]
bin/ed/test/e4.t [deleted file]
bin/ed/test/eq.err [deleted file]
bin/ed/test/f1.err [deleted file]
bin/ed/test/f2.err [deleted file]
bin/ed/test/g1.d [deleted file]
bin/ed/test/g1.err [deleted file]
bin/ed/test/g1.r [deleted file]
bin/ed/test/g1.t [deleted file]
bin/ed/test/g2.d [deleted file]
bin/ed/test/g2.err [deleted file]
bin/ed/test/g2.r [deleted file]
bin/ed/test/g2.t [deleted file]
bin/ed/test/g3.d [deleted file]
bin/ed/test/g3.err [deleted file]
bin/ed/test/g3.r [deleted file]
bin/ed/test/g3.t [deleted file]
bin/ed/test/g4.d [deleted file]
bin/ed/test/g4.r [deleted file]
bin/ed/test/g4.t [deleted file]
bin/ed/test/g5.d [deleted file]
bin/ed/test/g5.r [deleted file]
bin/ed/test/g5.t [deleted file]
bin/ed/test/h.err [deleted file]
bin/ed/test/i.d [deleted file]
bin/ed/test/i.r [deleted file]
bin/ed/test/i.t [deleted file]
bin/ed/test/i0.d [deleted file]
bin/ed/test/i0.r [deleted file]
bin/ed/test/i0.t [deleted file]
bin/ed/test/i1.err [deleted file]
bin/ed/test/i2.err [deleted file]
bin/ed/test/j.d [deleted file]
bin/ed/test/j.r [deleted file]
bin/ed/test/j.t [deleted file]
bin/ed/test/k.d [deleted file]
bin/ed/test/k.r [deleted file]
bin/ed/test/k.t [deleted file]
bin/ed/test/k1.err [deleted file]
bin/ed/test/k2.err [deleted file]
bin/ed/test/k3.err [deleted file]
bin/ed/test/k4.err [deleted file]
bin/ed/test/l.d [deleted file]
bin/ed/test/l.r [deleted file]
bin/ed/test/l.t [deleted file]
bin/ed/test/m.d [deleted file]
bin/ed/test/m.err [deleted file]
bin/ed/test/m.r [deleted file]
bin/ed/test/m.t [deleted file]
bin/ed/test/mkscripts.sh [deleted file]
bin/ed/test/n.d [deleted file]
bin/ed/test/n.r [deleted file]
bin/ed/test/n.t [deleted file]
bin/ed/test/nl1.d [deleted file]
bin/ed/test/nl1.r [deleted file]
bin/ed/test/nl1.t [deleted file]
bin/ed/test/nl2.d [deleted file]
bin/ed/test/nl2.r [deleted file]
bin/ed/test/nl2.t [deleted file]
bin/ed/test/p.d [deleted file]
bin/ed/test/p.r [deleted file]
bin/ed/test/p.t [deleted file]
bin/ed/test/q.d [deleted file]
bin/ed/test/q.r [deleted file]
bin/ed/test/q.t [deleted file]
bin/ed/test/q1.err [deleted file]
bin/ed/test/r1.d [deleted file]
bin/ed/test/r1.err [deleted file]
bin/ed/test/r1.r [deleted file]
bin/ed/test/r1.t [deleted file]
bin/ed/test/r2.d [deleted file]
bin/ed/test/r2.err [deleted file]
bin/ed/test/r2.r [deleted file]
bin/ed/test/r2.t [deleted file]
bin/ed/test/r3.d [deleted file]
bin/ed/test/r3.r [deleted file]
bin/ed/test/r3.t [deleted file]
bin/ed/test/s1.d [deleted file]
bin/ed/test/s1.err [deleted file]
bin/ed/test/s1.r [deleted file]
bin/ed/test/s1.t [deleted file]
bin/ed/test/s10.err [deleted file]
bin/ed/test/s2.d [deleted file]
bin/ed/test/s2.r [deleted file]
bin/ed/test/s2.t [deleted file]
bin/ed/test/s3.d [deleted file]
bin/ed/test/s3.err [deleted file]
bin/ed/test/s3.r [deleted file]
bin/ed/test/s3.t [deleted file]
bin/ed/test/s4.d [deleted file]
bin/ed/test/s4.err [deleted file]
bin/ed/test/s4.r [deleted file]
bin/ed/test/s4.t [deleted file]
bin/ed/test/s5.err [deleted file]
bin/ed/test/s6.err [deleted file]
bin/ed/test/s7.err [deleted file]
bin/ed/test/s8.err [deleted file]
bin/ed/test/s9.err [deleted file]
bin/ed/test/t.d [deleted file]
bin/ed/test/t.r [deleted file]
bin/ed/test/t.t [deleted file]
bin/ed/test/t1.d [deleted file]
bin/ed/test/t1.err [deleted file]
bin/ed/test/t1.r [deleted file]
bin/ed/test/t1.t [deleted file]
bin/ed/test/t2.d [deleted file]
bin/ed/test/t2.err [deleted file]
bin/ed/test/t2.r [deleted file]
bin/ed/test/t2.t [deleted file]
bin/ed/test/u.d [deleted file]
bin/ed/test/u.err [deleted file]
bin/ed/test/u.r [deleted file]
bin/ed/test/u.t [deleted file]
bin/ed/test/v.d [deleted file]
bin/ed/test/v.r [deleted file]
bin/ed/test/v.t [deleted file]
bin/ed/test/w.d [deleted file]
bin/ed/test/w.r [deleted file]
bin/ed/test/w.t [deleted file]
bin/ed/test/w1.err [deleted file]
bin/ed/test/w2.err [deleted file]
bin/ed/test/w3.err [deleted file]
bin/ed/test/x.err [deleted file]
bin/ed/test/z.err [deleted file]
regress/bin/ed/Makefile
regress/bin/ed/README [new file with mode: 0644]
regress/bin/ed/TODO [new file with mode: 0644]
regress/bin/ed/a.d [new file with mode: 0644]
regress/bin/ed/a.r [new file with mode: 0644]
regress/bin/ed/a.t [new file with mode: 0644]
regress/bin/ed/a1.err [new file with mode: 0644]
regress/bin/ed/a2.err [new file with mode: 0644]
regress/bin/ed/addr.d [new file with mode: 0644]
regress/bin/ed/addr.r [new file with mode: 0644]
regress/bin/ed/addr.t [new file with mode: 0644]
regress/bin/ed/addr1.err [new file with mode: 0644]
regress/bin/ed/addr2.err [new file with mode: 0644]
regress/bin/ed/ascii.d [new file with mode: 0644]
regress/bin/ed/ascii.r [new file with mode: 0644]
regress/bin/ed/ascii.t [new file with mode: 0644]
regress/bin/ed/bang1.d [new file with mode: 0644]
regress/bin/ed/bang1.err [new file with mode: 0644]
regress/bin/ed/bang1.r [new file with mode: 0644]
regress/bin/ed/bang1.t [new file with mode: 0644]
regress/bin/ed/bang2.err [new file with mode: 0644]
regress/bin/ed/c.d [new file with mode: 0644]
regress/bin/ed/c.r [new file with mode: 0644]
regress/bin/ed/c.t [new file with mode: 0644]
regress/bin/ed/c1.err [new file with mode: 0644]
regress/bin/ed/c2.err [new file with mode: 0644]
regress/bin/ed/ckscripts.sh [new file with mode: 0644]
regress/bin/ed/d.d [new file with mode: 0644]
regress/bin/ed/d.err [new file with mode: 0644]
regress/bin/ed/d.r [new file with mode: 0644]
regress/bin/ed/d.t [new file with mode: 0644]
regress/bin/ed/d0.d [new file with mode: 0644]
regress/bin/ed/d0.r [new file with mode: 0644]
regress/bin/ed/d0.t [new file with mode: 0644]
regress/bin/ed/d1.d [new file with mode: 0644]
regress/bin/ed/d1.r [new file with mode: 0644]
regress/bin/ed/d1.t [new file with mode: 0644]
regress/bin/ed/d2.d [new file with mode: 0644]
regress/bin/ed/d2.r [new file with mode: 0644]
regress/bin/ed/d2.t [new file with mode: 0644]
regress/bin/ed/d3.d [new file with mode: 0644]
regress/bin/ed/d3.r [new file with mode: 0644]
regress/bin/ed/d3.t [new file with mode: 0644]
regress/bin/ed/d4.d [new file with mode: 0644]
regress/bin/ed/d4.r [new file with mode: 0644]
regress/bin/ed/d4.t [new file with mode: 0644]
regress/bin/ed/d5.d [new file with mode: 0644]
regress/bin/ed/d5.r [new file with mode: 0644]
regress/bin/ed/d5.t [new file with mode: 0644]
regress/bin/ed/e1.d [new file with mode: 0644]
regress/bin/ed/e1.err [new file with mode: 0644]
regress/bin/ed/e1.r [new file with mode: 0644]
regress/bin/ed/e1.t [new file with mode: 0644]
regress/bin/ed/e2.d [new file with mode: 0644]
regress/bin/ed/e2.err [new file with mode: 0644]
regress/bin/ed/e2.r [new file with mode: 0644]
regress/bin/ed/e2.t [new file with mode: 0644]
regress/bin/ed/e3.d [new file with mode: 0644]
regress/bin/ed/e3.err [new file with mode: 0644]
regress/bin/ed/e3.r [new file with mode: 0644]
regress/bin/ed/e3.t [new file with mode: 0644]
regress/bin/ed/e4.d [new file with mode: 0644]
regress/bin/ed/e4.r [new file with mode: 0644]
regress/bin/ed/e4.t [new file with mode: 0644]
regress/bin/ed/eq.err [new file with mode: 0644]
regress/bin/ed/f1.err [new file with mode: 0644]
regress/bin/ed/f2.err [new file with mode: 0644]
regress/bin/ed/g1.d [new file with mode: 0644]
regress/bin/ed/g1.err [new file with mode: 0644]
regress/bin/ed/g1.r [new file with mode: 0644]
regress/bin/ed/g1.t [new file with mode: 0644]
regress/bin/ed/g2.d [new file with mode: 0644]
regress/bin/ed/g2.err [new file with mode: 0644]
regress/bin/ed/g2.r [new file with mode: 0644]
regress/bin/ed/g2.t [new file with mode: 0644]
regress/bin/ed/g3.d [new file with mode: 0644]
regress/bin/ed/g3.err [new file with mode: 0644]
regress/bin/ed/g3.r [new file with mode: 0644]
regress/bin/ed/g3.t [new file with mode: 0644]
regress/bin/ed/g4.d [new file with mode: 0644]
regress/bin/ed/g4.r [new file with mode: 0644]
regress/bin/ed/g4.t [new file with mode: 0644]
regress/bin/ed/g5.d [new file with mode: 0644]
regress/bin/ed/g5.r [new file with mode: 0644]
regress/bin/ed/g5.t [new file with mode: 0644]
regress/bin/ed/h.err [new file with mode: 0644]
regress/bin/ed/i.d [new file with mode: 0644]
regress/bin/ed/i.r [new file with mode: 0644]
regress/bin/ed/i.t [new file with mode: 0644]
regress/bin/ed/i0.d [new file with mode: 0644]
regress/bin/ed/i0.r [new file with mode: 0644]
regress/bin/ed/i0.t [new file with mode: 0644]
regress/bin/ed/i1.err [new file with mode: 0644]
regress/bin/ed/i2.err [new file with mode: 0644]
regress/bin/ed/j.d [new file with mode: 0644]
regress/bin/ed/j.r [new file with mode: 0644]
regress/bin/ed/j.t [new file with mode: 0644]
regress/bin/ed/k.d [new file with mode: 0644]
regress/bin/ed/k.r [new file with mode: 0644]
regress/bin/ed/k.t [new file with mode: 0644]
regress/bin/ed/k1.err [new file with mode: 0644]
regress/bin/ed/k2.err [new file with mode: 0644]
regress/bin/ed/k3.err [new file with mode: 0644]
regress/bin/ed/k4.err [new file with mode: 0644]
regress/bin/ed/l.d [new file with mode: 0644]
regress/bin/ed/l.r [new file with mode: 0644]
regress/bin/ed/l.t [new file with mode: 0644]
regress/bin/ed/m.d [new file with mode: 0644]
regress/bin/ed/m.err [new file with mode: 0644]
regress/bin/ed/m.r [new file with mode: 0644]
regress/bin/ed/m.t [new file with mode: 0644]
regress/bin/ed/mkscripts.sh [new file with mode: 0644]
regress/bin/ed/n.d [new file with mode: 0644]
regress/bin/ed/n.r [new file with mode: 0644]
regress/bin/ed/n.t [new file with mode: 0644]
regress/bin/ed/nl1.d [new file with mode: 0644]
regress/bin/ed/nl1.r [new file with mode: 0644]
regress/bin/ed/nl1.t [new file with mode: 0644]
regress/bin/ed/nl2.d [new file with mode: 0644]
regress/bin/ed/nl2.r [new file with mode: 0644]
regress/bin/ed/nl2.t [new file with mode: 0644]
regress/bin/ed/p.d [new file with mode: 0644]
regress/bin/ed/p.r [new file with mode: 0644]
regress/bin/ed/p.t [new file with mode: 0644]
regress/bin/ed/q.d [new file with mode: 0644]
regress/bin/ed/q.r [new file with mode: 0644]
regress/bin/ed/q.t [new file with mode: 0644]
regress/bin/ed/q1.err [new file with mode: 0644]
regress/bin/ed/r1.d [new file with mode: 0644]
regress/bin/ed/r1.err [new file with mode: 0644]
regress/bin/ed/r1.r [new file with mode: 0644]
regress/bin/ed/r1.t [new file with mode: 0644]
regress/bin/ed/r2.d [new file with mode: 0644]
regress/bin/ed/r2.err [new file with mode: 0644]
regress/bin/ed/r2.r [new file with mode: 0644]
regress/bin/ed/r2.t [new file with mode: 0644]
regress/bin/ed/r3.d [new file with mode: 0644]
regress/bin/ed/r3.r [new file with mode: 0644]
regress/bin/ed/r3.t [new file with mode: 0644]
regress/bin/ed/s1.d [new file with mode: 0644]
regress/bin/ed/s1.err [new file with mode: 0644]
regress/bin/ed/s1.r [new file with mode: 0644]
regress/bin/ed/s1.t [new file with mode: 0644]
regress/bin/ed/s10.err [new file with mode: 0644]
regress/bin/ed/s2.d [new file with mode: 0644]
regress/bin/ed/s2.r [new file with mode: 0644]
regress/bin/ed/s2.t [new file with mode: 0644]
regress/bin/ed/s3.d [new file with mode: 0644]
regress/bin/ed/s3.err [new file with mode: 0644]
regress/bin/ed/s3.r [new file with mode: 0644]
regress/bin/ed/s3.t [new file with mode: 0644]
regress/bin/ed/s4.d [new file with mode: 0644]
regress/bin/ed/s4.err [new file with mode: 0644]
regress/bin/ed/s4.r [new file with mode: 0644]
regress/bin/ed/s4.t [new file with mode: 0644]
regress/bin/ed/s5.err [new file with mode: 0644]
regress/bin/ed/s6.err [new file with mode: 0644]
regress/bin/ed/s7.err [new file with mode: 0644]
regress/bin/ed/s8.err [new file with mode: 0644]
regress/bin/ed/s9.err [new file with mode: 0644]
regress/bin/ed/t.d [new file with mode: 0644]
regress/bin/ed/t.r [new file with mode: 0644]
regress/bin/ed/t.t [new file with mode: 0644]
regress/bin/ed/t1.d [new file with mode: 0644]
regress/bin/ed/t1.err [new file with mode: 0644]
regress/bin/ed/t1.r [new file with mode: 0644]
regress/bin/ed/t1.t [new file with mode: 0644]
regress/bin/ed/t2.d [new file with mode: 0644]
regress/bin/ed/t2.err [new file with mode: 0644]
regress/bin/ed/t2.r [new file with mode: 0644]
regress/bin/ed/t2.t [new file with mode: 0644]
regress/bin/ed/u.d [new file with mode: 0644]
regress/bin/ed/u.err [new file with mode: 0644]
regress/bin/ed/u.r [new file with mode: 0644]
regress/bin/ed/u.t [new file with mode: 0644]
regress/bin/ed/v.d [new file with mode: 0644]
regress/bin/ed/v.r [new file with mode: 0644]
regress/bin/ed/v.t [new file with mode: 0644]
regress/bin/ed/w.d [new file with mode: 0644]
regress/bin/ed/w.r [new file with mode: 0644]
regress/bin/ed/w.t [new file with mode: 0644]
regress/bin/ed/w1.err [new file with mode: 0644]
regress/bin/ed/w2.err [new file with mode: 0644]
regress/bin/ed/w3.err [new file with mode: 0644]
regress/bin/ed/x.err [new file with mode: 0644]
regress/bin/ed/z.err [new file with mode: 0644]

diff --git a/bin/ed/test/Makefile b/bin/ed/test/Makefile
deleted file mode 100644 (file)
index de3e737..0000000
+++ /dev/null
@@ -1,26 +0,0 @@
-#      $OpenBSD: Makefile,v 1.2 1996/06/23 14:20:05 deraadt Exp $
-#      $NetBSD: Makefile,v 1.11 1995/03/21 09:05:14 cgd Exp $
-
-SHELL= /bin/sh
-ED=    ../obj/ed
-
-all: check
-       @:
-
-check: build test
-       @if grep -h '\*\*\*' errs.o scripts.o; then :; else \
-               echo "tests completed successfully."; \
-       fi
-
-build: mkscripts.sh
-       @if [ -f errs.o ]; then :; else \
-               echo "building test scripts for $(ED) ..."; \
-               $(SHELL) mkscripts.sh $(ED); \
-       fi
-
-test: build ckscripts.sh
-       @echo testing $(ED) ...
-       @$(SHELL) ckscripts.sh $(ED)
-
-clean:
-       rm -f *.ed *.red *.[oz] *~
diff --git a/bin/ed/test/README b/bin/ed/test/README
deleted file mode 100644 (file)
index 27ad28d..0000000
+++ /dev/null
@@ -1,33 +0,0 @@
-$OpenBSD: README,v 1.3 2018/01/09 00:43:10 bluhm Exp $
-$NetBSD: README,v 1.8 1995/03/21 09:05:18 cgd Exp $
-
-The files in this directory with suffixes `.t', `.d', `.r' and `.err' are
-used for testing ed.  To run the tests, set the ED variable in the Makefile
-for the path name of the program to be tested (e.g., /bin/ed), and type
-`make'.  The tests do not exhaustively verify POSIX compliance nor do
-they verify correct 8-bit or long line support.
-
-The test file suffixes have the following meanings:
-.t    Template - a list of ed commands from which an ed script is
-      constructed
-.d    Data - read by an ed script
-.r    Result - the expected output after processing data via an ed
-      script.
-.err  Error - invalid ed commands that should generate an error
-
-The output of the tests is written to the two files err.o and scripts.o.
-At the end of the tests, these files are grep'ed for error messages,
-which look like:
-       *** The script u.ed exited abnormally ***
-or:
-       *** Output u.o of script u.ed is incorrect ***
-
-The POSIX requirement that an address range not be used where at most
-a single address is expected has been relaxed in this version of ed.
-Therefore, the  following scripts  which test for compliance with this
-POSIX rule exit abnormally:
-a1-err.ed
-eq-err.ed
-i1-err.ed
-k1-err.ed
-r1-err.ed
diff --git a/bin/ed/test/TODO b/bin/ed/test/TODO
deleted file mode 100644 (file)
index a119709..0000000
+++ /dev/null
@@ -1,18 +0,0 @@
-$OpenBSD: TODO,v 1.2 1996/06/23 14:20:06 deraadt Exp $
-$NetBSD: TODO,v 1.3 1995/03/21 09:05:20 cgd Exp $
-
-Some missing tests:
-0) g/./s^@^@   - okay: NULs in commands
-1) g/./s/^@/   - okay: NULs in patterns
-2) a
-   hello^V^Jworld      
-   .           - okay: embedded newlines in insert mode
-3) ed ""       - error: invalid filename
-4) red ..      - error: restricted
-5) red /       - error: restricted
-5) red !xx     - error: restricted
-6) ed -x       - verify: 8-bit clean
-7) ed          - verify: long-line support
-8) ed          - verify: interactive/help mode
-9) G/pat/      - verify: global interactive command
-10) V/pat/     - verify: global interactive command
diff --git a/bin/ed/test/a.d b/bin/ed/test/a.d
deleted file mode 100644 (file)
index 92f337e..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-line 1
-line 2
-line 3
-line 4
-line5
diff --git a/bin/ed/test/a.r b/bin/ed/test/a.r
deleted file mode 100644 (file)
index 26257bd..0000000
+++ /dev/null
@@ -1,8 +0,0 @@
-hello world
-line 1
-hello world!
-line 2
-line 3
-line 4
-line5
-hello world!!
diff --git a/bin/ed/test/a.t b/bin/ed/test/a.t
deleted file mode 100644 (file)
index ac98c40..0000000
+++ /dev/null
@@ -1,9 +0,0 @@
-0a
-hello world
-.
-2a
-hello world!
-.
-$a
-hello world!!
-.
diff --git a/bin/ed/test/a1.err b/bin/ed/test/a1.err
deleted file mode 100644 (file)
index e80815f..0000000
+++ /dev/null
@@ -1,3 +0,0 @@
-1,$a
-hello world
-.
diff --git a/bin/ed/test/a2.err b/bin/ed/test/a2.err
deleted file mode 100644 (file)
index ec4b00b..0000000
+++ /dev/null
@@ -1,3 +0,0 @@
-aa
-hello world
-.
diff --git a/bin/ed/test/addr.d b/bin/ed/test/addr.d
deleted file mode 100644 (file)
index 8f7ba1b..0000000
+++ /dev/null
@@ -1,9 +0,0 @@
-line 1
-line 2
-line 3
-line 4
-line5
-1ine6
-line7
-line8
-line9
diff --git a/bin/ed/test/addr.r b/bin/ed/test/addr.r
deleted file mode 100644 (file)
index 04caf17..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-line 2
-line9
diff --git a/bin/ed/test/addr.t b/bin/ed/test/addr.t
deleted file mode 100644 (file)
index 750b224..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-1 d
-1 1 d
-1,2,d
-1;+ + ,d
-1,2;., + 2d
diff --git a/bin/ed/test/addr1.err b/bin/ed/test/addr1.err
deleted file mode 100644 (file)
index 29d6383..0000000
+++ /dev/null
@@ -1 +0,0 @@
-100
diff --git a/bin/ed/test/addr2.err b/bin/ed/test/addr2.err
deleted file mode 100644 (file)
index e96acb9..0000000
+++ /dev/null
@@ -1 +0,0 @@
--100
diff --git a/bin/ed/test/ascii.d b/bin/ed/test/ascii.d
deleted file mode 100644 (file)
index c866266..0000000
Binary files a/bin/ed/test/ascii.d and /dev/null differ
diff --git a/bin/ed/test/ascii.r b/bin/ed/test/ascii.r
deleted file mode 100644 (file)
index c866266..0000000
Binary files a/bin/ed/test/ascii.r and /dev/null differ
diff --git a/bin/ed/test/ascii.t b/bin/ed/test/ascii.t
deleted file mode 100644 (file)
index e69de29..0000000
diff --git a/bin/ed/test/bang1.d b/bin/ed/test/bang1.d
deleted file mode 100644 (file)
index e69de29..0000000
diff --git a/bin/ed/test/bang1.err b/bin/ed/test/bang1.err
deleted file mode 100644 (file)
index 630af90..0000000
+++ /dev/null
@@ -1 +0,0 @@
-.!date
diff --git a/bin/ed/test/bang1.r b/bin/ed/test/bang1.r
deleted file mode 100644 (file)
index dcf02b2..0000000
+++ /dev/null
@@ -1 +0,0 @@
-okay
diff --git a/bin/ed/test/bang1.t b/bin/ed/test/bang1.t
deleted file mode 100644 (file)
index d7b1fea..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-!read one
-hello, world
-a
-okay
-.
diff --git a/bin/ed/test/bang2.err b/bin/ed/test/bang2.err
deleted file mode 100644 (file)
index 79d8956..0000000
+++ /dev/null
@@ -1 +0,0 @@
-!!
diff --git a/bin/ed/test/c.d b/bin/ed/test/c.d
deleted file mode 100644 (file)
index 92f337e..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-line 1
-line 2
-line 3
-line 4
-line5
diff --git a/bin/ed/test/c.r b/bin/ed/test/c.r
deleted file mode 100644 (file)
index 0fb3e4f..0000000
+++ /dev/null
@@ -1,4 +0,0 @@
-at the top
-between top/middle
-in the middle
-at the bottom
diff --git a/bin/ed/test/c.t b/bin/ed/test/c.t
deleted file mode 100644 (file)
index ebdd536..0000000
+++ /dev/null
@@ -1,12 +0,0 @@
-1c
-at the top
-.
-4c
-in the middle
-.
-$c
-at the bottom
-.
-2,3c
-between top/middle
-.
diff --git a/bin/ed/test/c1.err b/bin/ed/test/c1.err
deleted file mode 100644 (file)
index 658ec38..0000000
+++ /dev/null
@@ -1,3 +0,0 @@
-cc
-hello world
-.
diff --git a/bin/ed/test/c2.err b/bin/ed/test/c2.err
deleted file mode 100644 (file)
index 24b3227..0000000
+++ /dev/null
@@ -1,3 +0,0 @@
-0c
-hello world
-.
diff --git a/bin/ed/test/ckscripts.sh b/bin/ed/test/ckscripts.sh
deleted file mode 100644 (file)
index b401a79..0000000
+++ /dev/null
@@ -1,38 +0,0 @@
-#!/bin/sh -
-#      $OpenBSD: ckscripts.sh,v 1.3 1998/07/12 03:49:08 todd Exp $
-#      $NetBSD: ckscripts.sh,v 1.9 1995/04/23 10:07:34 cgd Exp $
-#
-# This script runs the .ed scripts generated by mkscripts.sh
-# and compares their output against the .r files, which contain
-# the correct output
-
-PATH="/bin:/usr/bin:/usr/local/bin/:."
-ED=$1
-[ ! -x $ED ] && { echo "$ED: cannot execute"; exit 1; }
-
-# Run the *.red scripts first, since these don't generate output;
-# they exit with non-zero status
-for i in *.red; do
-       echo $i
-       if $i; then
-               echo "*** The script $i exited abnormally  ***"
-       fi
-done >errs.o 2>&1
-
-# Run the remaining scripts; they exit with zero status
-for i in *.ed; do
-#      base=`expr $i : '\([^.]*\)'`
-#      base=`echo $i | sed 's/\..*//'`
-       base=`$ED - \!"echo $i" <<-EOF
-               s/\..*
-       EOF`
-       if $base.ed; then
-               if cmp -s $base.o $base.r; then :; else
-                       echo "*** Output $base.o of script $i is incorrect ***"
-               fi
-       else
-               echo "*** The script $i exited abnormally ***"
-       fi
-done >scripts.o 2>&1
-
-grep -h '\*\*\*' errs.o scripts.o
diff --git a/bin/ed/test/d.d b/bin/ed/test/d.d
deleted file mode 100644 (file)
index 92f337e..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-line 1
-line 2
-line 3
-line 4
-line5
diff --git a/bin/ed/test/d.err b/bin/ed/test/d.err
deleted file mode 100644 (file)
index f03f694..0000000
+++ /dev/null
@@ -1 +0,0 @@
-dd
diff --git a/bin/ed/test/d.r b/bin/ed/test/d.r
deleted file mode 100644 (file)
index b7e242c..0000000
+++ /dev/null
@@ -1 +0,0 @@
-line 2
diff --git a/bin/ed/test/d.t b/bin/ed/test/d.t
deleted file mode 100644 (file)
index c7c473f..0000000
+++ /dev/null
@@ -1,3 +0,0 @@
-1d
-2;+1d
-$d
diff --git a/bin/ed/test/d0.d b/bin/ed/test/d0.d
deleted file mode 100644 (file)
index 92f337e..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-line 1
-line 2
-line 3
-line 4
-line5
diff --git a/bin/ed/test/d0.r b/bin/ed/test/d0.r
deleted file mode 100644 (file)
index e69de29..0000000
diff --git a/bin/ed/test/d0.t b/bin/ed/test/d0.t
deleted file mode 100644 (file)
index 5725f10..0000000
+++ /dev/null
@@ -1 +0,0 @@
-,d
diff --git a/bin/ed/test/d1.d b/bin/ed/test/d1.d
deleted file mode 100644 (file)
index 92f337e..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-line 1
-line 2
-line 3
-line 4
-line5
diff --git a/bin/ed/test/d1.r b/bin/ed/test/d1.r
deleted file mode 100644 (file)
index 071c8f3..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-line 4
-line5
diff --git a/bin/ed/test/d1.t b/bin/ed/test/d1.t
deleted file mode 100644 (file)
index 0bdfc29..0000000
+++ /dev/null
@@ -1 +0,0 @@
-,3d
diff --git a/bin/ed/test/d2.d b/bin/ed/test/d2.d
deleted file mode 100644 (file)
index 92f337e..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-line 1
-line 2
-line 3
-line 4
-line5
diff --git a/bin/ed/test/d2.r b/bin/ed/test/d2.r
deleted file mode 100644 (file)
index c29a1e3..0000000
+++ /dev/null
@@ -1,4 +0,0 @@
-line 1
-line 2
-line 4
-line5
diff --git a/bin/ed/test/d2.t b/bin/ed/test/d2.t
deleted file mode 100644 (file)
index 34a3f8d..0000000
+++ /dev/null
@@ -1 +0,0 @@
-3,d
diff --git a/bin/ed/test/d3.d b/bin/ed/test/d3.d
deleted file mode 100644 (file)
index 92f337e..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-line 1
-line 2
-line 3
-line 4
-line5
diff --git a/bin/ed/test/d3.r b/bin/ed/test/d3.r
deleted file mode 100644 (file)
index 89b24ec..0000000
+++ /dev/null
@@ -1 +0,0 @@
-line 1
diff --git a/bin/ed/test/d3.t b/bin/ed/test/d3.t
deleted file mode 100644 (file)
index 50996be..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-2
-;d
diff --git a/bin/ed/test/d4.d b/bin/ed/test/d4.d
deleted file mode 100644 (file)
index 92f337e..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-line 1
-line 2
-line 3
-line 4
-line5
diff --git a/bin/ed/test/d4.r b/bin/ed/test/d4.r
deleted file mode 100644 (file)
index 0d1bbcf..0000000
+++ /dev/null
@@ -1,3 +0,0 @@
-line 1
-line 4
-line5
diff --git a/bin/ed/test/d4.t b/bin/ed/test/d4.t
deleted file mode 100644 (file)
index 9ebddc6..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-2
-;3d
diff --git a/bin/ed/test/d5.d b/bin/ed/test/d5.d
deleted file mode 100644 (file)
index 92f337e..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-line 1
-line 2
-line 3
-line 4
-line5
diff --git a/bin/ed/test/d5.r b/bin/ed/test/d5.r
deleted file mode 100644 (file)
index c29a1e3..0000000
+++ /dev/null
@@ -1,4 +0,0 @@
-line 1
-line 2
-line 4
-line5
diff --git a/bin/ed/test/d5.t b/bin/ed/test/d5.t
deleted file mode 100644 (file)
index ef303a6..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-4
-3;d
diff --git a/bin/ed/test/e1.d b/bin/ed/test/e1.d
deleted file mode 100644 (file)
index 3b18e51..0000000
+++ /dev/null
@@ -1 +0,0 @@
-hello world
diff --git a/bin/ed/test/e1.err b/bin/ed/test/e1.err
deleted file mode 100644 (file)
index 827cc29..0000000
+++ /dev/null
@@ -1 +0,0 @@
-ee e1.err
diff --git a/bin/ed/test/e1.r b/bin/ed/test/e1.r
deleted file mode 100644 (file)
index e656728..0000000
+++ /dev/null
@@ -1 +0,0 @@
-E e1.t
diff --git a/bin/ed/test/e1.t b/bin/ed/test/e1.t
deleted file mode 100644 (file)
index e656728..0000000
+++ /dev/null
@@ -1 +0,0 @@
-E e1.t
diff --git a/bin/ed/test/e2.d b/bin/ed/test/e2.d
deleted file mode 100644 (file)
index aa44630..0000000
+++ /dev/null
@@ -1 +0,0 @@
-E !echo hello world-
diff --git a/bin/ed/test/e2.err b/bin/ed/test/e2.err
deleted file mode 100644 (file)
index 779a64b..0000000
+++ /dev/null
@@ -1 +0,0 @@
-.e e2.err
diff --git a/bin/ed/test/e2.r b/bin/ed/test/e2.r
deleted file mode 100644 (file)
index 59ebf11..0000000
+++ /dev/null
@@ -1 +0,0 @@
-hello world-
diff --git a/bin/ed/test/e2.t b/bin/ed/test/e2.t
deleted file mode 100644 (file)
index aa44630..0000000
+++ /dev/null
@@ -1 +0,0 @@
-E !echo hello world-
diff --git a/bin/ed/test/e3.d b/bin/ed/test/e3.d
deleted file mode 100644 (file)
index aa44630..0000000
+++ /dev/null
@@ -1 +0,0 @@
-E !echo hello world-
diff --git a/bin/ed/test/e3.err b/bin/ed/test/e3.err
deleted file mode 100644 (file)
index 80a7fdc..0000000
+++ /dev/null
@@ -1 +0,0 @@
-ee.err
diff --git a/bin/ed/test/e3.r b/bin/ed/test/e3.r
deleted file mode 100644 (file)
index aa44630..0000000
+++ /dev/null
@@ -1 +0,0 @@
-E !echo hello world-
diff --git a/bin/ed/test/e3.t b/bin/ed/test/e3.t
deleted file mode 100644 (file)
index 1c50726..0000000
+++ /dev/null
@@ -1 +0,0 @@
-E
diff --git a/bin/ed/test/e4.d b/bin/ed/test/e4.d
deleted file mode 100644 (file)
index aa44630..0000000
+++ /dev/null
@@ -1 +0,0 @@
-E !echo hello world-
diff --git a/bin/ed/test/e4.r b/bin/ed/test/e4.r
deleted file mode 100644 (file)
index aa44630..0000000
+++ /dev/null
@@ -1 +0,0 @@
-E !echo hello world-
diff --git a/bin/ed/test/e4.t b/bin/ed/test/e4.t
deleted file mode 100644 (file)
index d905d9d..0000000
+++ /dev/null
@@ -1 +0,0 @@
-e
diff --git a/bin/ed/test/eq.err b/bin/ed/test/eq.err
deleted file mode 100644 (file)
index 6a60559..0000000
+++ /dev/null
@@ -1 +0,0 @@
-1,$=
diff --git a/bin/ed/test/f1.err b/bin/ed/test/f1.err
deleted file mode 100644 (file)
index e60975a..0000000
+++ /dev/null
@@ -1 +0,0 @@
-.f f1.err
diff --git a/bin/ed/test/f2.err b/bin/ed/test/f2.err
deleted file mode 100644 (file)
index 26d1c5e..0000000
+++ /dev/null
@@ -1 +0,0 @@
-ff1.err
diff --git a/bin/ed/test/g1.d b/bin/ed/test/g1.d
deleted file mode 100644 (file)
index 92f337e..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-line 1
-line 2
-line 3
-line 4
-line5
diff --git a/bin/ed/test/g1.err b/bin/ed/test/g1.err
deleted file mode 100644 (file)
index f95ea22..0000000
+++ /dev/null
@@ -1 +0,0 @@
-g/./s //x/
diff --git a/bin/ed/test/g1.r b/bin/ed/test/g1.r
deleted file mode 100644 (file)
index 578a44b..0000000
+++ /dev/null
@@ -1,15 +0,0 @@
-line5
-help! world
-order
-line 4
-help! world
-order
-line 3
-help! world
-order
-line 2
-help! world
-order
-line 1
-help! world
-order
diff --git a/bin/ed/test/g1.t b/bin/ed/test/g1.t
deleted file mode 100644 (file)
index 2d0b54f..0000000
+++ /dev/null
@@ -1,6 +0,0 @@
-g/./m0
-g/./s/$/\
-hello world
-g/hello /s/lo/p!/\
-a\
-order
diff --git a/bin/ed/test/g2.d b/bin/ed/test/g2.d
deleted file mode 100644 (file)
index 92f337e..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-line 1
-line 2
-line 3
-line 4
-line5
diff --git a/bin/ed/test/g2.err b/bin/ed/test/g2.err
deleted file mode 100644 (file)
index 0ff6a5a..0000000
+++ /dev/null
@@ -1 +0,0 @@
-g//s/./x/
diff --git a/bin/ed/test/g2.r b/bin/ed/test/g2.r
deleted file mode 100644 (file)
index 3b18e51..0000000
+++ /dev/null
@@ -1 +0,0 @@
-hello world
diff --git a/bin/ed/test/g2.t b/bin/ed/test/g2.t
deleted file mode 100644 (file)
index 831ee83..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-g/[2-4]/-1,+1c\
-hello world
diff --git a/bin/ed/test/g3.d b/bin/ed/test/g3.d
deleted file mode 100644 (file)
index 92f337e..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-line 1
-line 2
-line 3
-line 4
-line5
diff --git a/bin/ed/test/g3.err b/bin/ed/test/g3.err
deleted file mode 100644 (file)
index 01058d8..0000000
+++ /dev/null
@@ -1 +0,0 @@
-g
diff --git a/bin/ed/test/g3.r b/bin/ed/test/g3.r
deleted file mode 100644 (file)
index cc6fbdd..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-linc 3
-xine 1
-xine 2
-xinc 4
-xinc5
diff --git a/bin/ed/test/g3.t b/bin/ed/test/g3.t
deleted file mode 100644 (file)
index 2d052a6..0000000
+++ /dev/null
@@ -1,4 +0,0 @@
-g/./s//x/\
-3m0
-g/./s/e/c/\
-2,3m1
diff --git a/bin/ed/test/g4.d b/bin/ed/test/g4.d
deleted file mode 100644 (file)
index 92f337e..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-line 1
-line 2
-line 3
-line 4
-line5
diff --git a/bin/ed/test/g4.r b/bin/ed/test/g4.r
deleted file mode 100644 (file)
index 350882d..0000000
+++ /dev/null
@@ -1,7 +0,0 @@
-hello
-zine 1
-line 2
-line 3
-line 4
-line5
-world
diff --git a/bin/ed/test/g4.t b/bin/ed/test/g4.t
deleted file mode 100644 (file)
index ec61816..0000000
+++ /dev/null
@@ -1,13 +0,0 @@
-g/./s/./x/\
-u\
-s/./y/\
-u\
-s/./z/\
-u
-u
-0a
-hello
-.
-$a
-world
-.
diff --git a/bin/ed/test/g5.d b/bin/ed/test/g5.d
deleted file mode 100644 (file)
index a92d664..0000000
+++ /dev/null
@@ -1,3 +0,0 @@
-line 1
-line 2
-line 3
diff --git a/bin/ed/test/g5.r b/bin/ed/test/g5.r
deleted file mode 100644 (file)
index 15a2675..0000000
+++ /dev/null
@@ -1,9 +0,0 @@
-line 1
-line 2
-line 3
-line 2
-line 3
-line 1
-line 3
-line 1
-line 2
diff --git a/bin/ed/test/g5.t b/bin/ed/test/g5.t
deleted file mode 100644 (file)
index e213481..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-g/./1,3t$\
-1d
diff --git a/bin/ed/test/h.err b/bin/ed/test/h.err
deleted file mode 100644 (file)
index a71e506..0000000
+++ /dev/null
@@ -1 +0,0 @@
-.h
diff --git a/bin/ed/test/i.d b/bin/ed/test/i.d
deleted file mode 100644 (file)
index 92f337e..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-line 1
-line 2
-line 3
-line 4
-line5
diff --git a/bin/ed/test/i.r b/bin/ed/test/i.r
deleted file mode 100644 (file)
index 5f27af0..0000000
+++ /dev/null
@@ -1,8 +0,0 @@
-hello world
-hello world!
-line 1
-line 2
-line 3
-line 4
-hello world!!
-line5
diff --git a/bin/ed/test/i.t b/bin/ed/test/i.t
deleted file mode 100644 (file)
index d1d9805..0000000
+++ /dev/null
@@ -1,9 +0,0 @@
-1i
-hello world
-.
-2i
-hello world!
-.
-$i
-hello world!!
-.
diff --git a/bin/ed/test/i0.d b/bin/ed/test/i0.d
deleted file mode 100644 (file)
index a29bdeb..0000000
+++ /dev/null
@@ -1 +0,0 @@
-line1
diff --git a/bin/ed/test/i0.r b/bin/ed/test/i0.r
deleted file mode 100644 (file)
index 0134f39..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-hello world
-line1
diff --git a/bin/ed/test/i0.t b/bin/ed/test/i0.t
deleted file mode 100644 (file)
index 6d200c8..0000000
+++ /dev/null
@@ -1,3 +0,0 @@
-0i
-hello world
-.
diff --git a/bin/ed/test/i1.err b/bin/ed/test/i1.err
deleted file mode 100644 (file)
index aaddede..0000000
+++ /dev/null
@@ -1,3 +0,0 @@
-1,$i
-hello world
-.
diff --git a/bin/ed/test/i2.err b/bin/ed/test/i2.err
deleted file mode 100644 (file)
index b63f5ac..0000000
+++ /dev/null
@@ -1,3 +0,0 @@
-ii
-hello world
-.
diff --git a/bin/ed/test/j.d b/bin/ed/test/j.d
deleted file mode 100644 (file)
index 92f337e..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-line 1
-line 2
-line 3
-line 4
-line5
diff --git a/bin/ed/test/j.r b/bin/ed/test/j.r
deleted file mode 100644 (file)
index 66f36a8..0000000
+++ /dev/null
@@ -1,4 +0,0 @@
-line 1
-line 2line 3
-line 4
-line5
diff --git a/bin/ed/test/j.t b/bin/ed/test/j.t
deleted file mode 100644 (file)
index 9b5d28d..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-1,1j
-2,3j
diff --git a/bin/ed/test/k.d b/bin/ed/test/k.d
deleted file mode 100644 (file)
index 92f337e..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-line 1
-line 2
-line 3
-line 4
-line5
diff --git a/bin/ed/test/k.r b/bin/ed/test/k.r
deleted file mode 100644 (file)
index eeb38db..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-line 3
-hello world
-line 4
-line5
-line 2
diff --git a/bin/ed/test/k.t b/bin/ed/test/k.t
deleted file mode 100644 (file)
index 53d588d..0000000
+++ /dev/null
@@ -1,10 +0,0 @@
-2ka
-1d
-'am$
-1ka
-0a
-hello world
-.
-'ad
-u
-'am0
diff --git a/bin/ed/test/k1.err b/bin/ed/test/k1.err
deleted file mode 100644 (file)
index eba1f3d..0000000
+++ /dev/null
@@ -1 +0,0 @@
-1,$ka
diff --git a/bin/ed/test/k2.err b/bin/ed/test/k2.err
deleted file mode 100644 (file)
index b34a18d..0000000
+++ /dev/null
@@ -1 +0,0 @@
-kA
diff --git a/bin/ed/test/k3.err b/bin/ed/test/k3.err
deleted file mode 100644 (file)
index 70190c4..0000000
+++ /dev/null
@@ -1 +0,0 @@
-0ka
diff --git a/bin/ed/test/k4.err b/bin/ed/test/k4.err
deleted file mode 100644 (file)
index 3457642..0000000
+++ /dev/null
@@ -1,6 +0,0 @@
-a
-hello
-.
-.ka
-'ad
-'ap
diff --git a/bin/ed/test/l.d b/bin/ed/test/l.d
deleted file mode 100644 (file)
index e69de29..0000000
diff --git a/bin/ed/test/l.r b/bin/ed/test/l.r
deleted file mode 100644 (file)
index e69de29..0000000
diff --git a/bin/ed/test/l.t b/bin/ed/test/l.t
deleted file mode 100644 (file)
index e69de29..0000000
diff --git a/bin/ed/test/m.d b/bin/ed/test/m.d
deleted file mode 100644 (file)
index 92f337e..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-line 1
-line 2
-line 3
-line 4
-line5
diff --git a/bin/ed/test/m.err b/bin/ed/test/m.err
deleted file mode 100644 (file)
index 3aec4c3..0000000
+++ /dev/null
@@ -1,4 +0,0 @@
-a
-hello world
-.
-1,$m1
diff --git a/bin/ed/test/m.r b/bin/ed/test/m.r
deleted file mode 100644 (file)
index 186cf54..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-line5
-line 1
-line 2
-line 3
-line 4
diff --git a/bin/ed/test/m.t b/bin/ed/test/m.t
deleted file mode 100644 (file)
index c39c088..0000000
+++ /dev/null
@@ -1,7 +0,0 @@
-1,2m$
-1,2m$
-1,2m$
-$m0
-$m0
-2,3m1
-2,3m3
diff --git a/bin/ed/test/mkscripts.sh b/bin/ed/test/mkscripts.sh
deleted file mode 100644 (file)
index 2bf9b21..0000000
+++ /dev/null
@@ -1,76 +0,0 @@
-#!/bin/sh -
-#      $OpenBSD: mkscripts.sh,v 1.2 1996/06/23 14:20:08 deraadt Exp $
-#      $NetBSD: mkscripts.sh,v 1.10 1995/04/23 10:07:36 cgd Exp $
-#
-# This script generates ed test scripts (.ed) from .t files
-
-PATH="/bin:/usr/bin:/usr/local/bin/:."
-ED=$1
-[ ! -x $ED ] && { echo "$ED: cannot execute"; exit 1; }
-
-for i in *.t; do
-#      base=${i%.*}
-#      base=`echo $i | sed 's/\..*//'`
-#      base=`expr $i : '\([^.]*\)'`
-#      (
-#      echo "#!/bin/sh -"
-#      echo "$ED - <<\EOT"
-#      echo "r $base.d"
-#      cat $i
-#      echo "w $base.o"
-#      echo EOT
-#      ) >$base.ed
-#      chmod +x $base.ed
-# The following is pretty ugly way of doing the above, and not appropriate 
-# use of ed  but the point is that it can be done...
-       base=`$ED - \!"echo $i" <<-EOF
-               s/\..*
-       EOF`
-       $ED - <<-EOF
-               a
-               #!/bin/sh -
-               $ED - <<\EOT
-               H
-               r $base.d
-               w $base.o
-               EOT
-               .
-               -2r $i
-               w $base.ed
-               !chmod +x $base.ed
-       EOF
-done
-
-for i in *.err; do
-#      base=${i%.*}
-#      base=`echo $i | sed 's/\..*//'`
-#      base=`expr $i : '\([^.]*\)'`
-#      (
-#      echo "#!/bin/sh -"
-#      echo "$ED - <<\EOT"
-#      echo H
-#      echo "r $base.err"
-#      cat $i
-#      echo "w $base.o"
-#      echo EOT
-#      ) >$base-err.ed
-#      chmod +x $base-err.ed
-# The following is pretty ugly way of doing the above, and not appropriate 
-# use of ed  but the point is that it can be done...
-       base=`$ED - \!"echo $i" <<-EOF
-               s/\..*
-       EOF`
-       $ED - <<-EOF
-               a
-               #!/bin/sh -
-               $ED - <<\EOT
-               H
-               r $base.err
-               w $base.o
-               EOT
-               .
-               -2r $i
-               w ${base}.red
-               !chmod +x ${base}.red
-       EOF
-done
diff --git a/bin/ed/test/n.d b/bin/ed/test/n.d
deleted file mode 100644 (file)
index e69de29..0000000
diff --git a/bin/ed/test/n.r b/bin/ed/test/n.r
deleted file mode 100644 (file)
index e69de29..0000000
diff --git a/bin/ed/test/n.t b/bin/ed/test/n.t
deleted file mode 100644 (file)
index e69de29..0000000
diff --git a/bin/ed/test/nl1.d b/bin/ed/test/nl1.d
deleted file mode 100644 (file)
index 92f337e..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-line 1
-line 2
-line 3
-line 4
-line5
diff --git a/bin/ed/test/nl1.r b/bin/ed/test/nl1.r
deleted file mode 100644 (file)
index 9d8854c..0000000
+++ /dev/null
@@ -1,8 +0,0 @@
-
-
-hello world
-line 1
-line 2
-line 3
-line 4
-line5
diff --git a/bin/ed/test/nl1.t b/bin/ed/test/nl1.t
deleted file mode 100644 (file)
index ea192e9..0000000
+++ /dev/null
@@ -1,8 +0,0 @@
-1
-
-
-0a
-
-
-hello world
-.
diff --git a/bin/ed/test/nl2.d b/bin/ed/test/nl2.d
deleted file mode 100644 (file)
index 92f337e..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-line 1
-line 2
-line 3
-line 4
-line5
diff --git a/bin/ed/test/nl2.r b/bin/ed/test/nl2.r
deleted file mode 100644 (file)
index fe99e41..0000000
+++ /dev/null
@@ -1,6 +0,0 @@
-line 1
-line 2
-line 3
-line 4
-line5
-hello world
diff --git a/bin/ed/test/nl2.t b/bin/ed/test/nl2.t
deleted file mode 100644 (file)
index 73fd27b..0000000
+++ /dev/null
@@ -1,4 +0,0 @@
-a
-hello world
-.
-0;/./
diff --git a/bin/ed/test/p.d b/bin/ed/test/p.d
deleted file mode 100644 (file)
index e69de29..0000000
diff --git a/bin/ed/test/p.r b/bin/ed/test/p.r
deleted file mode 100644 (file)
index e69de29..0000000
diff --git a/bin/ed/test/p.t b/bin/ed/test/p.t
deleted file mode 100644 (file)
index e69de29..0000000
diff --git a/bin/ed/test/q.d b/bin/ed/test/q.d
deleted file mode 100644 (file)
index e69de29..0000000
diff --git a/bin/ed/test/q.r b/bin/ed/test/q.r
deleted file mode 100644 (file)
index e69de29..0000000
diff --git a/bin/ed/test/q.t b/bin/ed/test/q.t
deleted file mode 100644 (file)
index 123a2c8..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-w q.o
-a
-hello
-.
-q
diff --git a/bin/ed/test/q1.err b/bin/ed/test/q1.err
deleted file mode 100644 (file)
index 0a7e178..0000000
+++ /dev/null
@@ -1 +0,0 @@
-.q
diff --git a/bin/ed/test/r1.d b/bin/ed/test/r1.d
deleted file mode 100644 (file)
index 92f337e..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-line 1
-line 2
-line 3
-line 4
-line5
diff --git a/bin/ed/test/r1.err b/bin/ed/test/r1.err
deleted file mode 100644 (file)
index 269aa7c..0000000
+++ /dev/null
@@ -1 +0,0 @@
-1,$r r1.err
diff --git a/bin/ed/test/r1.r b/bin/ed/test/r1.r
deleted file mode 100644 (file)
index a3ff506..0000000
+++ /dev/null
@@ -1,7 +0,0 @@
-line 1
-hello world
-line 2
-line 3
-line 4
-line5
-hello world
diff --git a/bin/ed/test/r1.t b/bin/ed/test/r1.t
deleted file mode 100644 (file)
index d787a92..0000000
+++ /dev/null
@@ -1,3 +0,0 @@
-1;r !echo hello world
-1
-r !echo hello world
diff --git a/bin/ed/test/r2.d b/bin/ed/test/r2.d
deleted file mode 100644 (file)
index 92f337e..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-line 1
-line 2
-line 3
-line 4
-line5
diff --git a/bin/ed/test/r2.err b/bin/ed/test/r2.err
deleted file mode 100644 (file)
index 1c44fa3..0000000
+++ /dev/null
@@ -1 +0,0 @@
-r a-good-book
diff --git a/bin/ed/test/r2.r b/bin/ed/test/r2.r
deleted file mode 100644 (file)
index ac152ba..0000000
+++ /dev/null
@@ -1,10 +0,0 @@
-line 1
-line 2
-line 3
-line 4
-line5
-line 1
-line 2
-line 3
-line 4
-line5
diff --git a/bin/ed/test/r2.t b/bin/ed/test/r2.t
deleted file mode 100644 (file)
index 4286f42..0000000
+++ /dev/null
@@ -1 +0,0 @@
-r
diff --git a/bin/ed/test/r3.d b/bin/ed/test/r3.d
deleted file mode 100644 (file)
index 593eec6..0000000
+++ /dev/null
@@ -1 +0,0 @@
-r r3.t
diff --git a/bin/ed/test/r3.r b/bin/ed/test/r3.r
deleted file mode 100644 (file)
index 86d5f90..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-r r3.t
-r r3.t
diff --git a/bin/ed/test/r3.t b/bin/ed/test/r3.t
deleted file mode 100644 (file)
index 593eec6..0000000
+++ /dev/null
@@ -1 +0,0 @@
-r r3.t
diff --git a/bin/ed/test/s1.d b/bin/ed/test/s1.d
deleted file mode 100644 (file)
index 92f337e..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-line 1
-line 2
-line 3
-line 4
-line5
diff --git a/bin/ed/test/s1.err b/bin/ed/test/s1.err
deleted file mode 100644 (file)
index d7ca0cf..0000000
+++ /dev/null
@@ -1 +0,0 @@
-s . x
diff --git a/bin/ed/test/s1.r b/bin/ed/test/s1.r
deleted file mode 100644 (file)
index 4eb0980..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-liene 1
-(liene) (2)
-(liene) (3)
-liene (4)
-(()liene5)
diff --git a/bin/ed/test/s1.t b/bin/ed/test/s1.t
deleted file mode 100644 (file)
index b0028bb..0000000
+++ /dev/null
@@ -1,6 +0,0 @@
-s/\([^ ][^ ]*\)/(\1)/g
-2s
-/3/s
-/\(4\)/sr
-/\(.\)/srg
-%s/i/&e/
diff --git a/bin/ed/test/s10.err b/bin/ed/test/s10.err
deleted file mode 100644 (file)
index 0d8d83d..0000000
+++ /dev/null
@@ -1,4 +0,0 @@
-a
-hello
-.
-s/[h[.]/x/
diff --git a/bin/ed/test/s2.d b/bin/ed/test/s2.d
deleted file mode 100644 (file)
index 92f337e..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-line 1
-line 2
-line 3
-line 4
-line5
diff --git a/bin/ed/test/s2.r b/bin/ed/test/s2.r
deleted file mode 100644 (file)
index ca305c8..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-li(n)e 1
-i(n)e 200
-li(n)e 3
-li(n)e 4
-li(n)e500
diff --git a/bin/ed/test/s2.t b/bin/ed/test/s2.t
deleted file mode 100644 (file)
index f365849..0000000
+++ /dev/null
@@ -1,4 +0,0 @@
-,s/./(&)/3
-s/$/00
-2s//%/g
-s/^l
diff --git a/bin/ed/test/s3.d b/bin/ed/test/s3.d
deleted file mode 100644 (file)
index e69de29..0000000
diff --git a/bin/ed/test/s3.err b/bin/ed/test/s3.err
deleted file mode 100644 (file)
index d68c7d0..0000000
+++ /dev/null
@@ -1 +0,0 @@
-s/[xyx/a/
diff --git a/bin/ed/test/s3.r b/bin/ed/test/s3.r
deleted file mode 100644 (file)
index d6cada2..0000000
+++ /dev/null
@@ -1 +0,0 @@
-hello   world
diff --git a/bin/ed/test/s3.t b/bin/ed/test/s3.t
deleted file mode 100644 (file)
index fbf8803..0000000
+++ /dev/null
@@ -1,6 +0,0 @@
-a
-hello/[]world
-.
-s/[/]/ /
-s/[[:digit:][]/ /
-s/[]]/ /
diff --git a/bin/ed/test/s4.d b/bin/ed/test/s4.d
deleted file mode 100644 (file)
index 7898192..0000000
+++ /dev/null
@@ -1 +0,0 @@
-a
diff --git a/bin/ed/test/s4.err b/bin/ed/test/s4.err
deleted file mode 100644 (file)
index 35b609f..0000000
+++ /dev/null
@@ -1 +0,0 @@
-s/\a\b\c/xyz/
diff --git a/bin/ed/test/s4.r b/bin/ed/test/s4.r
deleted file mode 100644 (file)
index 86ae29c..0000000
+++ /dev/null
@@ -1 +0,0 @@
-ba
diff --git a/bin/ed/test/s4.t b/bin/ed/test/s4.t
deleted file mode 100644 (file)
index 5e4fe76..0000000
+++ /dev/null
@@ -1 +0,0 @@
-s/x*/b/g
diff --git a/bin/ed/test/s5.err b/bin/ed/test/s5.err
deleted file mode 100644 (file)
index 89104c5..0000000
+++ /dev/null
@@ -1 +0,0 @@
-s//xyz/
diff --git a/bin/ed/test/s6.err b/bin/ed/test/s6.err
deleted file mode 100644 (file)
index b478595..0000000
+++ /dev/null
@@ -1 +0,0 @@
-s
diff --git a/bin/ed/test/s7.err b/bin/ed/test/s7.err
deleted file mode 100644 (file)
index 30ba4fd..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-a
-hello world
-.
-/./
-sr
diff --git a/bin/ed/test/s8.err b/bin/ed/test/s8.err
deleted file mode 100644 (file)
index 5665767..0000000
+++ /dev/null
@@ -1,4 +0,0 @@
-a
-hello
-.
-s/[h[=]/x/
diff --git a/bin/ed/test/s9.err b/bin/ed/test/s9.err
deleted file mode 100644 (file)
index 1ff16dd..0000000
+++ /dev/null
@@ -1,4 +0,0 @@
-a
-hello
-.
-s/[h[:]/x/
diff --git a/bin/ed/test/t.d b/bin/ed/test/t.d
deleted file mode 100644 (file)
index 92f337e..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-line 1
-line 2
-line 3
-line 4
-line5
diff --git a/bin/ed/test/t.r b/bin/ed/test/t.r
deleted file mode 100644 (file)
index 2b28547..0000000
+++ /dev/null
@@ -1,16 +0,0 @@
-line 1
-line 1
-line 1
-line 2
-line 2
-line 3
-line 4
-line5
-line 1
-line 1
-line 1
-line 2
-line 2
-line 3
-line 4
-line5
diff --git a/bin/ed/test/t.t b/bin/ed/test/t.t
deleted file mode 100644 (file)
index fcb1368..0000000
+++ /dev/null
@@ -1,3 +0,0 @@
-1t1
-2,3t2
-,t$
diff --git a/bin/ed/test/t1.d b/bin/ed/test/t1.d
deleted file mode 100644 (file)
index 92f337e..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-line 1
-line 2
-line 3
-line 4
-line5
diff --git a/bin/ed/test/t1.err b/bin/ed/test/t1.err
deleted file mode 100644 (file)
index c49c556..0000000
+++ /dev/null
@@ -1 +0,0 @@
-tt
diff --git a/bin/ed/test/t1.r b/bin/ed/test/t1.r
deleted file mode 100644 (file)
index 2b28547..0000000
+++ /dev/null
@@ -1,16 +0,0 @@
-line 1
-line 1
-line 1
-line 2
-line 2
-line 3
-line 4
-line5
-line 1
-line 1
-line 1
-line 2
-line 2
-line 3
-line 4
-line5
diff --git a/bin/ed/test/t1.t b/bin/ed/test/t1.t
deleted file mode 100644 (file)
index 6b66163..0000000
+++ /dev/null
@@ -1,3 +0,0 @@
-1t0
-2,3t2
-,t$
diff --git a/bin/ed/test/t2.d b/bin/ed/test/t2.d
deleted file mode 100644 (file)
index 92f337e..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-line 1
-line 2
-line 3
-line 4
-line5
diff --git a/bin/ed/test/t2.err b/bin/ed/test/t2.err
deleted file mode 100644 (file)
index c202051..0000000
+++ /dev/null
@@ -1 +0,0 @@
-t0;-1
diff --git a/bin/ed/test/t2.r b/bin/ed/test/t2.r
deleted file mode 100644 (file)
index 0c75ff5..0000000
+++ /dev/null
@@ -1,6 +0,0 @@
-line 1
-line5
-line 2
-line 3
-line 4
-line5
diff --git a/bin/ed/test/t2.t b/bin/ed/test/t2.t
deleted file mode 100644 (file)
index 5175abd..0000000
+++ /dev/null
@@ -1 +0,0 @@
-t0;/./
diff --git a/bin/ed/test/u.d b/bin/ed/test/u.d
deleted file mode 100644 (file)
index 92f337e..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-line 1
-line 2
-line 3
-line 4
-line5
diff --git a/bin/ed/test/u.err b/bin/ed/test/u.err
deleted file mode 100644 (file)
index caa1ba1..0000000
+++ /dev/null
@@ -1 +0,0 @@
-.u
diff --git a/bin/ed/test/u.r b/bin/ed/test/u.r
deleted file mode 100644 (file)
index ad558d8..0000000
+++ /dev/null
@@ -1,9 +0,0 @@
-line 1
-hello
-hello world!!
-line 2
-line 3
-line 4
-line5
-hello
-hello world!!
diff --git a/bin/ed/test/u.t b/bin/ed/test/u.t
deleted file mode 100644 (file)
index 131cb6e..0000000
+++ /dev/null
@@ -1,31 +0,0 @@
-1;r u.t
-u
-a
-hello
-world
-.
-g/./s//x/\
-a\
-hello\
-world
-u
-u
-u
-a
-hello world!
-.
-u
-1,$d
-u
-2,3d
-u
-c
-hello world!!
-.
-u
-u
--1;.,+1j
-u
-u
-u
-.,+1t$
diff --git a/bin/ed/test/v.d b/bin/ed/test/v.d
deleted file mode 100644 (file)
index 92f337e..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-line 1
-line 2
-line 3
-line 4
-line5
diff --git a/bin/ed/test/v.r b/bin/ed/test/v.r
deleted file mode 100644 (file)
index 714db63..0000000
+++ /dev/null
@@ -1,11 +0,0 @@
-line5
-order
-hello world
-line 1
-order
-line 2
-order
-line 3
-order
-line 4
-order
diff --git a/bin/ed/test/v.t b/bin/ed/test/v.t
deleted file mode 100644 (file)
index 608a77f..0000000
+++ /dev/null
@@ -1,6 +0,0 @@
-v/[ ]/m0
-v/[ ]/s/$/\
-hello world
-v/hello /s/lo/p!/\
-a\
-order
diff --git a/bin/ed/test/w.d b/bin/ed/test/w.d
deleted file mode 100644 (file)
index 92f337e..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-line 1
-line 2
-line 3
-line 4
-line5
diff --git a/bin/ed/test/w.r b/bin/ed/test/w.r
deleted file mode 100644 (file)
index ac152ba..0000000
+++ /dev/null
@@ -1,10 +0,0 @@
-line 1
-line 2
-line 3
-line 4
-line5
-line 1
-line 2
-line 3
-line 4
-line5
diff --git a/bin/ed/test/w.t b/bin/ed/test/w.t
deleted file mode 100644 (file)
index c2e18bd..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-w !cat >\!.z
-r \!.z
diff --git a/bin/ed/test/w1.err b/bin/ed/test/w1.err
deleted file mode 100644 (file)
index e2c8a60..0000000
+++ /dev/null
@@ -1 +0,0 @@
-w /to/some/far-away/place
diff --git a/bin/ed/test/w2.err b/bin/ed/test/w2.err
deleted file mode 100644 (file)
index 9daf89c..0000000
+++ /dev/null
@@ -1 +0,0 @@
-ww.o
diff --git a/bin/ed/test/w3.err b/bin/ed/test/w3.err
deleted file mode 100644 (file)
index 39bbf4c..0000000
+++ /dev/null
@@ -1 +0,0 @@
-wqp w.o
diff --git a/bin/ed/test/x.err b/bin/ed/test/x.err
deleted file mode 100644 (file)
index 0953f01..0000000
+++ /dev/null
@@ -1 +0,0 @@
-.x
diff --git a/bin/ed/test/z.err b/bin/ed/test/z.err
deleted file mode 100644 (file)
index 6a51a2d..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-z
-z
index a4654d5..b4c0230 100644 (file)
@@ -1,7 +1,7 @@
-# $OpenBSD: Makefile,v 1.3 2020/12/17 00:51:11 bluhm Exp $
+# $OpenBSD: Makefile,v 1.4 2024/08/19 01:43:23 deraadt Exp $
 
 ED ?=          /bin/ed
-TESTDIR =      ${.CURDIR}/../../../bin/ed/test
+TESTDIR =      ${.CURDIR}
 
 TS !=          cd ${TESTDIR} && ls *.t
 ERRS !=                cd ${TESTDIR} && ls *.err
diff --git a/regress/bin/ed/README b/regress/bin/ed/README
new file mode 100644 (file)
index 0000000..aba7599
--- /dev/null
@@ -0,0 +1,33 @@
+$OpenBSD: README,v 1.1 2024/08/19 01:43:23 deraadt Exp $
+$NetBSD: README,v 1.8 1995/03/21 09:05:18 cgd Exp $
+
+The files in this directory with suffixes `.t', `.d', `.r' and `.err' are
+used for testing ed.  To run the tests, set the ED variable in the Makefile
+for the path name of the program to be tested (e.g., /bin/ed), and type
+`make'.  The tests do not exhaustively verify POSIX compliance nor do
+they verify correct 8-bit or long line support.
+
+The test file suffixes have the following meanings:
+.t    Template - a list of ed commands from which an ed script is
+      constructed
+.d    Data - read by an ed script
+.r    Result - the expected output after processing data via an ed
+      script.
+.err  Error - invalid ed commands that should generate an error
+
+The output of the tests is written to the two files err.o and scripts.o.
+At the end of the tests, these files are grep'ed for error messages,
+which look like:
+       *** The script u.ed exited abnormally ***
+or:
+       *** Output u.o of script u.ed is incorrect ***
+
+The POSIX requirement that an address range not be used where at most
+a single address is expected has been relaxed in this version of ed.
+Therefore, the  following scripts  which test for compliance with this
+POSIX rule exit abnormally:
+a1-err.ed
+eq-err.ed
+i1-err.ed
+k1-err.ed
+r1-err.ed
diff --git a/regress/bin/ed/TODO b/regress/bin/ed/TODO
new file mode 100644 (file)
index 0000000..cb566f6
--- /dev/null
@@ -0,0 +1,18 @@
+$OpenBSD: TODO,v 1.1 2024/08/19 01:43:23 deraadt Exp $
+$NetBSD: TODO,v 1.3 1995/03/21 09:05:20 cgd Exp $
+
+Some missing tests:
+0) g/./s^@^@   - okay: NULs in commands
+1) g/./s/^@/   - okay: NULs in patterns
+2) a
+   hello^V^Jworld      
+   .           - okay: embedded newlines in insert mode
+3) ed ""       - error: invalid filename
+4) red ..      - error: restricted
+5) red /       - error: restricted
+5) red !xx     - error: restricted
+6) ed -x       - verify: 8-bit clean
+7) ed          - verify: long-line support
+8) ed          - verify: interactive/help mode
+9) G/pat/      - verify: global interactive command
+10) V/pat/     - verify: global interactive command
diff --git a/regress/bin/ed/a.d b/regress/bin/ed/a.d
new file mode 100644 (file)
index 0000000..92f337e
--- /dev/null
@@ -0,0 +1,5 @@
+line 1
+line 2
+line 3
+line 4
+line5
diff --git a/regress/bin/ed/a.r b/regress/bin/ed/a.r
new file mode 100644 (file)
index 0000000..26257bd
--- /dev/null
@@ -0,0 +1,8 @@
+hello world
+line 1
+hello world!
+line 2
+line 3
+line 4
+line5
+hello world!!
diff --git a/regress/bin/ed/a.t b/regress/bin/ed/a.t
new file mode 100644 (file)
index 0000000..ac98c40
--- /dev/null
@@ -0,0 +1,9 @@
+0a
+hello world
+.
+2a
+hello world!
+.
+$a
+hello world!!
+.
diff --git a/regress/bin/ed/a1.err b/regress/bin/ed/a1.err
new file mode 100644 (file)
index 0000000..e80815f
--- /dev/null
@@ -0,0 +1,3 @@
+1,$a
+hello world
+.
diff --git a/regress/bin/ed/a2.err b/regress/bin/ed/a2.err
new file mode 100644 (file)
index 0000000..ec4b00b
--- /dev/null
@@ -0,0 +1,3 @@
+aa
+hello world
+.
diff --git a/regress/bin/ed/addr.d b/regress/bin/ed/addr.d
new file mode 100644 (file)
index 0000000..8f7ba1b
--- /dev/null
@@ -0,0 +1,9 @@
+line 1
+line 2
+line 3
+line 4
+line5
+1ine6
+line7
+line8
+line9
diff --git a/regress/bin/ed/addr.r b/regress/bin/ed/addr.r
new file mode 100644 (file)
index 0000000..04caf17
--- /dev/null
@@ -0,0 +1,2 @@
+line 2
+line9
diff --git a/regress/bin/ed/addr.t b/regress/bin/ed/addr.t
new file mode 100644 (file)
index 0000000..750b224
--- /dev/null
@@ -0,0 +1,5 @@
+1 d
+1 1 d
+1,2,d
+1;+ + ,d
+1,2;., + 2d
diff --git a/regress/bin/ed/addr1.err b/regress/bin/ed/addr1.err
new file mode 100644 (file)
index 0000000..29d6383
--- /dev/null
@@ -0,0 +1 @@
+100
diff --git a/regress/bin/ed/addr2.err b/regress/bin/ed/addr2.err
new file mode 100644 (file)
index 0000000..e96acb9
--- /dev/null
@@ -0,0 +1 @@
+-100
diff --git a/regress/bin/ed/ascii.d b/regress/bin/ed/ascii.d
new file mode 100644 (file)
index 0000000..c866266
Binary files /dev/null and b/regress/bin/ed/ascii.d differ
diff --git a/regress/bin/ed/ascii.r b/regress/bin/ed/ascii.r
new file mode 100644 (file)
index 0000000..c866266
Binary files /dev/null and b/regress/bin/ed/ascii.r differ
diff --git a/regress/bin/ed/ascii.t b/regress/bin/ed/ascii.t
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/regress/bin/ed/bang1.d b/regress/bin/ed/bang1.d
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/regress/bin/ed/bang1.err b/regress/bin/ed/bang1.err
new file mode 100644 (file)
index 0000000..630af90
--- /dev/null
@@ -0,0 +1 @@
+.!date
diff --git a/regress/bin/ed/bang1.r b/regress/bin/ed/bang1.r
new file mode 100644 (file)
index 0000000..dcf02b2
--- /dev/null
@@ -0,0 +1 @@
+okay
diff --git a/regress/bin/ed/bang1.t b/regress/bin/ed/bang1.t
new file mode 100644 (file)
index 0000000..d7b1fea
--- /dev/null
@@ -0,0 +1,5 @@
+!read one
+hello, world
+a
+okay
+.
diff --git a/regress/bin/ed/bang2.err b/regress/bin/ed/bang2.err
new file mode 100644 (file)
index 0000000..79d8956
--- /dev/null
@@ -0,0 +1 @@
+!!
diff --git a/regress/bin/ed/c.d b/regress/bin/ed/c.d
new file mode 100644 (file)
index 0000000..92f337e
--- /dev/null
@@ -0,0 +1,5 @@
+line 1
+line 2
+line 3
+line 4
+line5
diff --git a/regress/bin/ed/c.r b/regress/bin/ed/c.r
new file mode 100644 (file)
index 0000000..0fb3e4f
--- /dev/null
@@ -0,0 +1,4 @@
+at the top
+between top/middle
+in the middle
+at the bottom
diff --git a/regress/bin/ed/c.t b/regress/bin/ed/c.t
new file mode 100644 (file)
index 0000000..ebdd536
--- /dev/null
@@ -0,0 +1,12 @@
+1c
+at the top
+.
+4c
+in the middle
+.
+$c
+at the bottom
+.
+2,3c
+between top/middle
+.
diff --git a/regress/bin/ed/c1.err b/regress/bin/ed/c1.err
new file mode 100644 (file)
index 0000000..658ec38
--- /dev/null
@@ -0,0 +1,3 @@
+cc
+hello world
+.
diff --git a/regress/bin/ed/c2.err b/regress/bin/ed/c2.err
new file mode 100644 (file)
index 0000000..24b3227
--- /dev/null
@@ -0,0 +1,3 @@
+0c
+hello world
+.
diff --git a/regress/bin/ed/ckscripts.sh b/regress/bin/ed/ckscripts.sh
new file mode 100644 (file)
index 0000000..a8ee9e7
--- /dev/null
@@ -0,0 +1,38 @@
+#!/bin/sh -
+#      $OpenBSD: ckscripts.sh,v 1.1 2024/08/19 01:43:23 deraadt Exp $
+#      $NetBSD: ckscripts.sh,v 1.9 1995/04/23 10:07:34 cgd Exp $
+#
+# This script runs the .ed scripts generated by mkscripts.sh
+# and compares their output against the .r files, which contain
+# the correct output
+
+PATH="/bin:/usr/bin:/usr/local/bin/:."
+ED=$1
+[ ! -x $ED ] && { echo "$ED: cannot execute"; exit 1; }
+
+# Run the *.red scripts first, since these don't generate output;
+# they exit with non-zero status
+for i in *.red; do
+       echo $i
+       if $i; then
+               echo "*** The script $i exited abnormally  ***"
+       fi
+done >errs.o 2>&1
+
+# Run the remaining scripts; they exit with zero status
+for i in *.ed; do
+#      base=`expr $i : '\([^.]*\)'`
+#      base=`echo $i | sed 's/\..*//'`
+       base=`$ED - \!"echo $i" <<-EOF
+               s/\..*
+       EOF`
+       if $base.ed; then
+               if cmp -s $base.o $base.r; then :; else
+                       echo "*** Output $base.o of script $i is incorrect ***"
+               fi
+       else
+               echo "*** The script $i exited abnormally ***"
+       fi
+done >scripts.o 2>&1
+
+grep -h '\*\*\*' errs.o scripts.o
diff --git a/regress/bin/ed/d.d b/regress/bin/ed/d.d
new file mode 100644 (file)
index 0000000..92f337e
--- /dev/null
@@ -0,0 +1,5 @@
+line 1
+line 2
+line 3
+line 4
+line5
diff --git a/regress/bin/ed/d.err b/regress/bin/ed/d.err
new file mode 100644 (file)
index 0000000..f03f694
--- /dev/null
@@ -0,0 +1 @@
+dd
diff --git a/regress/bin/ed/d.r b/regress/bin/ed/d.r
new file mode 100644 (file)
index 0000000..b7e242c
--- /dev/null
@@ -0,0 +1 @@
+line 2
diff --git a/regress/bin/ed/d.t b/regress/bin/ed/d.t
new file mode 100644 (file)
index 0000000..c7c473f
--- /dev/null
@@ -0,0 +1,3 @@
+1d
+2;+1d
+$d
diff --git a/regress/bin/ed/d0.d b/regress/bin/ed/d0.d
new file mode 100644 (file)
index 0000000..92f337e
--- /dev/null
@@ -0,0 +1,5 @@
+line 1
+line 2
+line 3
+line 4
+line5
diff --git a/regress/bin/ed/d0.r b/regress/bin/ed/d0.r
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/regress/bin/ed/d0.t b/regress/bin/ed/d0.t
new file mode 100644 (file)
index 0000000..5725f10
--- /dev/null
@@ -0,0 +1 @@
+,d
diff --git a/regress/bin/ed/d1.d b/regress/bin/ed/d1.d
new file mode 100644 (file)
index 0000000..92f337e
--- /dev/null
@@ -0,0 +1,5 @@
+line 1
+line 2
+line 3
+line 4
+line5
diff --git a/regress/bin/ed/d1.r b/regress/bin/ed/d1.r
new file mode 100644 (file)
index 0000000..071c8f3
--- /dev/null
@@ -0,0 +1,2 @@
+line 4
+line5
diff --git a/regress/bin/ed/d1.t b/regress/bin/ed/d1.t
new file mode 100644 (file)
index 0000000..0bdfc29
--- /dev/null
@@ -0,0 +1 @@
+,3d
diff --git a/regress/bin/ed/d2.d b/regress/bin/ed/d2.d
new file mode 100644 (file)
index 0000000..92f337e
--- /dev/null
@@ -0,0 +1,5 @@
+line 1
+line 2
+line 3
+line 4
+line5
diff --git a/regress/bin/ed/d2.r b/regress/bin/ed/d2.r
new file mode 100644 (file)
index 0000000..c29a1e3
--- /dev/null
@@ -0,0 +1,4 @@
+line 1
+line 2
+line 4
+line5
diff --git a/regress/bin/ed/d2.t b/regress/bin/ed/d2.t
new file mode 100644 (file)
index 0000000..34a3f8d
--- /dev/null
@@ -0,0 +1 @@
+3,d
diff --git a/regress/bin/ed/d3.d b/regress/bin/ed/d3.d
new file mode 100644 (file)
index 0000000..92f337e
--- /dev/null
@@ -0,0 +1,5 @@
+line 1
+line 2
+line 3
+line 4
+line5
diff --git a/regress/bin/ed/d3.r b/regress/bin/ed/d3.r
new file mode 100644 (file)
index 0000000..89b24ec
--- /dev/null
@@ -0,0 +1 @@
+line 1
diff --git a/regress/bin/ed/d3.t b/regress/bin/ed/d3.t
new file mode 100644 (file)
index 0000000..50996be
--- /dev/null
@@ -0,0 +1,2 @@
+2
+;d
diff --git a/regress/bin/ed/d4.d b/regress/bin/ed/d4.d
new file mode 100644 (file)
index 0000000..92f337e
--- /dev/null
@@ -0,0 +1,5 @@
+line 1
+line 2
+line 3
+line 4
+line5
diff --git a/regress/bin/ed/d4.r b/regress/bin/ed/d4.r
new file mode 100644 (file)
index 0000000..0d1bbcf
--- /dev/null
@@ -0,0 +1,3 @@
+line 1
+line 4
+line5
diff --git a/regress/bin/ed/d4.t b/regress/bin/ed/d4.t
new file mode 100644 (file)
index 0000000..9ebddc6
--- /dev/null
@@ -0,0 +1,2 @@
+2
+;3d
diff --git a/regress/bin/ed/d5.d b/regress/bin/ed/d5.d
new file mode 100644 (file)
index 0000000..92f337e
--- /dev/null
@@ -0,0 +1,5 @@
+line 1
+line 2
+line 3
+line 4
+line5
diff --git a/regress/bin/ed/d5.r b/regress/bin/ed/d5.r
new file mode 100644 (file)
index 0000000..c29a1e3
--- /dev/null
@@ -0,0 +1,4 @@
+line 1
+line 2
+line 4
+line5
diff --git a/regress/bin/ed/d5.t b/regress/bin/ed/d5.t
new file mode 100644 (file)
index 0000000..ef303a6
--- /dev/null
@@ -0,0 +1,2 @@
+4
+3;d
diff --git a/regress/bin/ed/e1.d b/regress/bin/ed/e1.d
new file mode 100644 (file)
index 0000000..3b18e51
--- /dev/null
@@ -0,0 +1 @@
+hello world
diff --git a/regress/bin/ed/e1.err b/regress/bin/ed/e1.err
new file mode 100644 (file)
index 0000000..827cc29
--- /dev/null
@@ -0,0 +1 @@
+ee e1.err
diff --git a/regress/bin/ed/e1.r b/regress/bin/ed/e1.r
new file mode 100644 (file)
index 0000000..e656728
--- /dev/null
@@ -0,0 +1 @@
+E e1.t
diff --git a/regress/bin/ed/e1.t b/regress/bin/ed/e1.t
new file mode 100644 (file)
index 0000000..e656728
--- /dev/null
@@ -0,0 +1 @@
+E e1.t
diff --git a/regress/bin/ed/e2.d b/regress/bin/ed/e2.d
new file mode 100644 (file)
index 0000000..aa44630
--- /dev/null
@@ -0,0 +1 @@
+E !echo hello world-
diff --git a/regress/bin/ed/e2.err b/regress/bin/ed/e2.err
new file mode 100644 (file)
index 0000000..779a64b
--- /dev/null
@@ -0,0 +1 @@
+.e e2.err
diff --git a/regress/bin/ed/e2.r b/regress/bin/ed/e2.r
new file mode 100644 (file)
index 0000000..59ebf11
--- /dev/null
@@ -0,0 +1 @@
+hello world-
diff --git a/regress/bin/ed/e2.t b/regress/bin/ed/e2.t
new file mode 100644 (file)
index 0000000..aa44630
--- /dev/null
@@ -0,0 +1 @@
+E !echo hello world-
diff --git a/regress/bin/ed/e3.d b/regress/bin/ed/e3.d
new file mode 100644 (file)
index 0000000..aa44630
--- /dev/null
@@ -0,0 +1 @@
+E !echo hello world-
diff --git a/regress/bin/ed/e3.err b/regress/bin/ed/e3.err
new file mode 100644 (file)
index 0000000..80a7fdc
--- /dev/null
@@ -0,0 +1 @@
+ee.err
diff --git a/regress/bin/ed/e3.r b/regress/bin/ed/e3.r
new file mode 100644 (file)
index 0000000..aa44630
--- /dev/null
@@ -0,0 +1 @@
+E !echo hello world-
diff --git a/regress/bin/ed/e3.t b/regress/bin/ed/e3.t
new file mode 100644 (file)
index 0000000..1c50726
--- /dev/null
@@ -0,0 +1 @@
+E
diff --git a/regress/bin/ed/e4.d b/regress/bin/ed/e4.d
new file mode 100644 (file)
index 0000000..aa44630
--- /dev/null
@@ -0,0 +1 @@
+E !echo hello world-
diff --git a/regress/bin/ed/e4.r b/regress/bin/ed/e4.r
new file mode 100644 (file)
index 0000000..aa44630
--- /dev/null
@@ -0,0 +1 @@
+E !echo hello world-
diff --git a/regress/bin/ed/e4.t b/regress/bin/ed/e4.t
new file mode 100644 (file)
index 0000000..d905d9d
--- /dev/null
@@ -0,0 +1 @@
+e
diff --git a/regress/bin/ed/eq.err b/regress/bin/ed/eq.err
new file mode 100644 (file)
index 0000000..6a60559
--- /dev/null
@@ -0,0 +1 @@
+1,$=
diff --git a/regress/bin/ed/f1.err b/regress/bin/ed/f1.err
new file mode 100644 (file)
index 0000000..e60975a
--- /dev/null
@@ -0,0 +1 @@
+.f f1.err
diff --git a/regress/bin/ed/f2.err b/regress/bin/ed/f2.err
new file mode 100644 (file)
index 0000000..26d1c5e
--- /dev/null
@@ -0,0 +1 @@
+ff1.err
diff --git a/regress/bin/ed/g1.d b/regress/bin/ed/g1.d
new file mode 100644 (file)
index 0000000..92f337e
--- /dev/null
@@ -0,0 +1,5 @@
+line 1
+line 2
+line 3
+line 4
+line5
diff --git a/regress/bin/ed/g1.err b/regress/bin/ed/g1.err
new file mode 100644 (file)
index 0000000..f95ea22
--- /dev/null
@@ -0,0 +1 @@
+g/./s //x/
diff --git a/regress/bin/ed/g1.r b/regress/bin/ed/g1.r
new file mode 100644 (file)
index 0000000..578a44b
--- /dev/null
@@ -0,0 +1,15 @@
+line5
+help! world
+order
+line 4
+help! world
+order
+line 3
+help! world
+order
+line 2
+help! world
+order
+line 1
+help! world
+order
diff --git a/regress/bin/ed/g1.t b/regress/bin/ed/g1.t
new file mode 100644 (file)
index 0000000..2d0b54f
--- /dev/null
@@ -0,0 +1,6 @@
+g/./m0
+g/./s/$/\
+hello world
+g/hello /s/lo/p!/\
+a\
+order
diff --git a/regress/bin/ed/g2.d b/regress/bin/ed/g2.d
new file mode 100644 (file)
index 0000000..92f337e
--- /dev/null
@@ -0,0 +1,5 @@
+line 1
+line 2
+line 3
+line 4
+line5
diff --git a/regress/bin/ed/g2.err b/regress/bin/ed/g2.err
new file mode 100644 (file)
index 0000000..0ff6a5a
--- /dev/null
@@ -0,0 +1 @@
+g//s/./x/
diff --git a/regress/bin/ed/g2.r b/regress/bin/ed/g2.r
new file mode 100644 (file)
index 0000000..3b18e51
--- /dev/null
@@ -0,0 +1 @@
+hello world
diff --git a/regress/bin/ed/g2.t b/regress/bin/ed/g2.t
new file mode 100644 (file)
index 0000000..831ee83
--- /dev/null
@@ -0,0 +1,2 @@
+g/[2-4]/-1,+1c\
+hello world
diff --git a/regress/bin/ed/g3.d b/regress/bin/ed/g3.d
new file mode 100644 (file)
index 0000000..92f337e
--- /dev/null
@@ -0,0 +1,5 @@
+line 1
+line 2
+line 3
+line 4
+line5
diff --git a/regress/bin/ed/g3.err b/regress/bin/ed/g3.err
new file mode 100644 (file)
index 0000000..01058d8
--- /dev/null
@@ -0,0 +1 @@
+g
diff --git a/regress/bin/ed/g3.r b/regress/bin/ed/g3.r
new file mode 100644 (file)
index 0000000..cc6fbdd
--- /dev/null
@@ -0,0 +1,5 @@
+linc 3
+xine 1
+xine 2
+xinc 4
+xinc5
diff --git a/regress/bin/ed/g3.t b/regress/bin/ed/g3.t
new file mode 100644 (file)
index 0000000..2d052a6
--- /dev/null
@@ -0,0 +1,4 @@
+g/./s//x/\
+3m0
+g/./s/e/c/\
+2,3m1
diff --git a/regress/bin/ed/g4.d b/regress/bin/ed/g4.d
new file mode 100644 (file)
index 0000000..92f337e
--- /dev/null
@@ -0,0 +1,5 @@
+line 1
+line 2
+line 3
+line 4
+line5
diff --git a/regress/bin/ed/g4.r b/regress/bin/ed/g4.r
new file mode 100644 (file)
index 0000000..350882d
--- /dev/null
@@ -0,0 +1,7 @@
+hello
+zine 1
+line 2
+line 3
+line 4
+line5
+world
diff --git a/regress/bin/ed/g4.t b/regress/bin/ed/g4.t
new file mode 100644 (file)
index 0000000..ec61816
--- /dev/null
@@ -0,0 +1,13 @@
+g/./s/./x/\
+u\
+s/./y/\
+u\
+s/./z/\
+u
+u
+0a
+hello
+.
+$a
+world
+.
diff --git a/regress/bin/ed/g5.d b/regress/bin/ed/g5.d
new file mode 100644 (file)
index 0000000..a92d664
--- /dev/null
@@ -0,0 +1,3 @@
+line 1
+line 2
+line 3
diff --git a/regress/bin/ed/g5.r b/regress/bin/ed/g5.r
new file mode 100644 (file)
index 0000000..15a2675
--- /dev/null
@@ -0,0 +1,9 @@
+line 1
+line 2
+line 3
+line 2
+line 3
+line 1
+line 3
+line 1
+line 2
diff --git a/regress/bin/ed/g5.t b/regress/bin/ed/g5.t
new file mode 100644 (file)
index 0000000..e213481
--- /dev/null
@@ -0,0 +1,2 @@
+g/./1,3t$\
+1d
diff --git a/regress/bin/ed/h.err b/regress/bin/ed/h.err
new file mode 100644 (file)
index 0000000..a71e506
--- /dev/null
@@ -0,0 +1 @@
+.h
diff --git a/regress/bin/ed/i.d b/regress/bin/ed/i.d
new file mode 100644 (file)
index 0000000..92f337e
--- /dev/null
@@ -0,0 +1,5 @@
+line 1
+line 2
+line 3
+line 4
+line5
diff --git a/regress/bin/ed/i.r b/regress/bin/ed/i.r
new file mode 100644 (file)
index 0000000..5f27af0
--- /dev/null
@@ -0,0 +1,8 @@
+hello world
+hello world!
+line 1
+line 2
+line 3
+line 4
+hello world!!
+line5
diff --git a/regress/bin/ed/i.t b/regress/bin/ed/i.t
new file mode 100644 (file)
index 0000000..d1d9805
--- /dev/null
@@ -0,0 +1,9 @@
+1i
+hello world
+.
+2i
+hello world!
+.
+$i
+hello world!!
+.
diff --git a/regress/bin/ed/i0.d b/regress/bin/ed/i0.d
new file mode 100644 (file)
index 0000000..a29bdeb
--- /dev/null
@@ -0,0 +1 @@
+line1
diff --git a/regress/bin/ed/i0.r b/regress/bin/ed/i0.r
new file mode 100644 (file)
index 0000000..0134f39
--- /dev/null
@@ -0,0 +1,2 @@
+hello world
+line1
diff --git a/regress/bin/ed/i0.t b/regress/bin/ed/i0.t
new file mode 100644 (file)
index 0000000..6d200c8
--- /dev/null
@@ -0,0 +1,3 @@
+0i
+hello world
+.
diff --git a/regress/bin/ed/i1.err b/regress/bin/ed/i1.err
new file mode 100644 (file)
index 0000000..aaddede
--- /dev/null
@@ -0,0 +1,3 @@
+1,$i
+hello world
+.
diff --git a/regress/bin/ed/i2.err b/regress/bin/ed/i2.err
new file mode 100644 (file)
index 0000000..b63f5ac
--- /dev/null
@@ -0,0 +1,3 @@
+ii
+hello world
+.
diff --git a/regress/bin/ed/j.d b/regress/bin/ed/j.d
new file mode 100644 (file)
index 0000000..92f337e
--- /dev/null
@@ -0,0 +1,5 @@
+line 1
+line 2
+line 3
+line 4
+line5
diff --git a/regress/bin/ed/j.r b/regress/bin/ed/j.r
new file mode 100644 (file)
index 0000000..66f36a8
--- /dev/null
@@ -0,0 +1,4 @@
+line 1
+line 2line 3
+line 4
+line5
diff --git a/regress/bin/ed/j.t b/regress/bin/ed/j.t
new file mode 100644 (file)
index 0000000..9b5d28d
--- /dev/null
@@ -0,0 +1,2 @@
+1,1j
+2,3j
diff --git a/regress/bin/ed/k.d b/regress/bin/ed/k.d
new file mode 100644 (file)
index 0000000..92f337e
--- /dev/null
@@ -0,0 +1,5 @@
+line 1
+line 2
+line 3
+line 4
+line5
diff --git a/regress/bin/ed/k.r b/regress/bin/ed/k.r
new file mode 100644 (file)
index 0000000..eeb38db
--- /dev/null
@@ -0,0 +1,5 @@
+line 3
+hello world
+line 4
+line5
+line 2
diff --git a/regress/bin/ed/k.t b/regress/bin/ed/k.t
new file mode 100644 (file)
index 0000000..53d588d
--- /dev/null
@@ -0,0 +1,10 @@
+2ka
+1d
+'am$
+1ka
+0a
+hello world
+.
+'ad
+u
+'am0
diff --git a/regress/bin/ed/k1.err b/regress/bin/ed/k1.err
new file mode 100644 (file)
index 0000000..eba1f3d
--- /dev/null
@@ -0,0 +1 @@
+1,$ka
diff --git a/regress/bin/ed/k2.err b/regress/bin/ed/k2.err
new file mode 100644 (file)
index 0000000..b34a18d
--- /dev/null
@@ -0,0 +1 @@
+kA
diff --git a/regress/bin/ed/k3.err b/regress/bin/ed/k3.err
new file mode 100644 (file)
index 0000000..70190c4
--- /dev/null
@@ -0,0 +1 @@
+0ka
diff --git a/regress/bin/ed/k4.err b/regress/bin/ed/k4.err
new file mode 100644 (file)
index 0000000..3457642
--- /dev/null
@@ -0,0 +1,6 @@
+a
+hello
+.
+.ka
+'ad
+'ap
diff --git a/regress/bin/ed/l.d b/regress/bin/ed/l.d
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/regress/bin/ed/l.r b/regress/bin/ed/l.r
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/regress/bin/ed/l.t b/regress/bin/ed/l.t
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/regress/bin/ed/m.d b/regress/bin/ed/m.d
new file mode 100644 (file)
index 0000000..92f337e
--- /dev/null
@@ -0,0 +1,5 @@
+line 1
+line 2
+line 3
+line 4
+line5
diff --git a/regress/bin/ed/m.err b/regress/bin/ed/m.err
new file mode 100644 (file)
index 0000000..3aec4c3
--- /dev/null
@@ -0,0 +1,4 @@
+a
+hello world
+.
+1,$m1
diff --git a/regress/bin/ed/m.r b/regress/bin/ed/m.r
new file mode 100644 (file)
index 0000000..186cf54
--- /dev/null
@@ -0,0 +1,5 @@
+line5
+line 1
+line 2
+line 3
+line 4
diff --git a/regress/bin/ed/m.t b/regress/bin/ed/m.t
new file mode 100644 (file)
index 0000000..c39c088
--- /dev/null
@@ -0,0 +1,7 @@
+1,2m$
+1,2m$
+1,2m$
+$m0
+$m0
+2,3m1
+2,3m3
diff --git a/regress/bin/ed/mkscripts.sh b/regress/bin/ed/mkscripts.sh
new file mode 100644 (file)
index 0000000..25c0a0a
--- /dev/null
@@ -0,0 +1,76 @@
+#!/bin/sh -
+#      $OpenBSD: mkscripts.sh,v 1.1 2024/08/19 01:43:23 deraadt Exp $
+#      $NetBSD: mkscripts.sh,v 1.10 1995/04/23 10:07:36 cgd Exp $
+#
+# This script generates ed test scripts (.ed) from .t files
+
+PATH="/bin:/usr/bin:/usr/local/bin/:."
+ED=$1
+[ ! -x $ED ] && { echo "$ED: cannot execute"; exit 1; }
+
+for i in *.t; do
+#      base=${i%.*}
+#      base=`echo $i | sed 's/\..*//'`
+#      base=`expr $i : '\([^.]*\)'`
+#      (
+#      echo "#!/bin/sh -"
+#      echo "$ED - <<\EOT"
+#      echo "r $base.d"
+#      cat $i
+#      echo "w $base.o"
+#      echo EOT
+#      ) >$base.ed
+#      chmod +x $base.ed
+# The following is pretty ugly way of doing the above, and not appropriate 
+# use of ed  but the point is that it can be done...
+       base=`$ED - \!"echo $i" <<-EOF
+               s/\..*
+       EOF`
+       $ED - <<-EOF
+               a
+               #!/bin/sh -
+               $ED - <<\EOT
+               H
+               r $base.d
+               w $base.o
+               EOT
+               .
+               -2r $i
+               w $base.ed
+               !chmod +x $base.ed
+       EOF
+done
+
+for i in *.err; do
+#      base=${i%.*}
+#      base=`echo $i | sed 's/\..*//'`
+#      base=`expr $i : '\([^.]*\)'`
+#      (
+#      echo "#!/bin/sh -"
+#      echo "$ED - <<\EOT"
+#      echo H
+#      echo "r $base.err"
+#      cat $i
+#      echo "w $base.o"
+#      echo EOT
+#      ) >$base-err.ed
+#      chmod +x $base-err.ed
+# The following is pretty ugly way of doing the above, and not appropriate 
+# use of ed  but the point is that it can be done...
+       base=`$ED - \!"echo $i" <<-EOF
+               s/\..*
+       EOF`
+       $ED - <<-EOF
+               a
+               #!/bin/sh -
+               $ED - <<\EOT
+               H
+               r $base.err
+               w $base.o
+               EOT
+               .
+               -2r $i
+               w ${base}.red
+               !chmod +x ${base}.red
+       EOF
+done
diff --git a/regress/bin/ed/n.d b/regress/bin/ed/n.d
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/regress/bin/ed/n.r b/regress/bin/ed/n.r
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/regress/bin/ed/n.t b/regress/bin/ed/n.t
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/regress/bin/ed/nl1.d b/regress/bin/ed/nl1.d
new file mode 100644 (file)
index 0000000..92f337e
--- /dev/null
@@ -0,0 +1,5 @@
+line 1
+line 2
+line 3
+line 4
+line5
diff --git a/regress/bin/ed/nl1.r b/regress/bin/ed/nl1.r
new file mode 100644 (file)
index 0000000..9d8854c
--- /dev/null
@@ -0,0 +1,8 @@
+
+
+hello world
+line 1
+line 2
+line 3
+line 4
+line5
diff --git a/regress/bin/ed/nl1.t b/regress/bin/ed/nl1.t
new file mode 100644 (file)
index 0000000..ea192e9
--- /dev/null
@@ -0,0 +1,8 @@
+1
+
+
+0a
+
+
+hello world
+.
diff --git a/regress/bin/ed/nl2.d b/regress/bin/ed/nl2.d
new file mode 100644 (file)
index 0000000..92f337e
--- /dev/null
@@ -0,0 +1,5 @@
+line 1
+line 2
+line 3
+line 4
+line5
diff --git a/regress/bin/ed/nl2.r b/regress/bin/ed/nl2.r
new file mode 100644 (file)
index 0000000..fe99e41
--- /dev/null
@@ -0,0 +1,6 @@
+line 1
+line 2
+line 3
+line 4
+line5
+hello world
diff --git a/regress/bin/ed/nl2.t b/regress/bin/ed/nl2.t
new file mode 100644 (file)
index 0000000..73fd27b
--- /dev/null
@@ -0,0 +1,4 @@
+a
+hello world
+.
+0;/./
diff --git a/regress/bin/ed/p.d b/regress/bin/ed/p.d
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/regress/bin/ed/p.r b/regress/bin/ed/p.r
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/regress/bin/ed/p.t b/regress/bin/ed/p.t
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/regress/bin/ed/q.d b/regress/bin/ed/q.d
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/regress/bin/ed/q.r b/regress/bin/ed/q.r
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/regress/bin/ed/q.t b/regress/bin/ed/q.t
new file mode 100644 (file)
index 0000000..123a2c8
--- /dev/null
@@ -0,0 +1,5 @@
+w q.o
+a
+hello
+.
+q
diff --git a/regress/bin/ed/q1.err b/regress/bin/ed/q1.err
new file mode 100644 (file)
index 0000000..0a7e178
--- /dev/null
@@ -0,0 +1 @@
+.q
diff --git a/regress/bin/ed/r1.d b/regress/bin/ed/r1.d
new file mode 100644 (file)
index 0000000..92f337e
--- /dev/null
@@ -0,0 +1,5 @@
+line 1
+line 2
+line 3
+line 4
+line5
diff --git a/regress/bin/ed/r1.err b/regress/bin/ed/r1.err
new file mode 100644 (file)
index 0000000..269aa7c
--- /dev/null
@@ -0,0 +1 @@
+1,$r r1.err
diff --git a/regress/bin/ed/r1.r b/regress/bin/ed/r1.r
new file mode 100644 (file)
index 0000000..a3ff506
--- /dev/null
@@ -0,0 +1,7 @@
+line 1
+hello world
+line 2
+line 3
+line 4
+line5
+hello world
diff --git a/regress/bin/ed/r1.t b/regress/bin/ed/r1.t
new file mode 100644 (file)
index 0000000..d787a92
--- /dev/null
@@ -0,0 +1,3 @@
+1;r !echo hello world
+1
+r !echo hello world
diff --git a/regress/bin/ed/r2.d b/regress/bin/ed/r2.d
new file mode 100644 (file)
index 0000000..92f337e
--- /dev/null
@@ -0,0 +1,5 @@
+line 1
+line 2
+line 3
+line 4
+line5
diff --git a/regress/bin/ed/r2.err b/regress/bin/ed/r2.err
new file mode 100644 (file)
index 0000000..1c44fa3
--- /dev/null
@@ -0,0 +1 @@
+r a-good-book
diff --git a/regress/bin/ed/r2.r b/regress/bin/ed/r2.r
new file mode 100644 (file)
index 0000000..ac152ba
--- /dev/null
@@ -0,0 +1,10 @@
+line 1
+line 2
+line 3
+line 4
+line5
+line 1
+line 2
+line 3
+line 4
+line5
diff --git a/regress/bin/ed/r2.t b/regress/bin/ed/r2.t
new file mode 100644 (file)
index 0000000..4286f42
--- /dev/null
@@ -0,0 +1 @@
+r
diff --git a/regress/bin/ed/r3.d b/regress/bin/ed/r3.d
new file mode 100644 (file)
index 0000000..593eec6
--- /dev/null
@@ -0,0 +1 @@
+r r3.t
diff --git a/regress/bin/ed/r3.r b/regress/bin/ed/r3.r
new file mode 100644 (file)
index 0000000..86d5f90
--- /dev/null
@@ -0,0 +1,2 @@
+r r3.t
+r r3.t
diff --git a/regress/bin/ed/r3.t b/regress/bin/ed/r3.t
new file mode 100644 (file)
index 0000000..593eec6
--- /dev/null
@@ -0,0 +1 @@
+r r3.t
diff --git a/regress/bin/ed/s1.d b/regress/bin/ed/s1.d
new file mode 100644 (file)
index 0000000..92f337e
--- /dev/null
@@ -0,0 +1,5 @@
+line 1
+line 2
+line 3
+line 4
+line5
diff --git a/regress/bin/ed/s1.err b/regress/bin/ed/s1.err
new file mode 100644 (file)
index 0000000..d7ca0cf
--- /dev/null
@@ -0,0 +1 @@
+s . x
diff --git a/regress/bin/ed/s1.r b/regress/bin/ed/s1.r
new file mode 100644 (file)
index 0000000..4eb0980
--- /dev/null
@@ -0,0 +1,5 @@
+liene 1
+(liene) (2)
+(liene) (3)
+liene (4)
+(()liene5)
diff --git a/regress/bin/ed/s1.t b/regress/bin/ed/s1.t
new file mode 100644 (file)
index 0000000..b0028bb
--- /dev/null
@@ -0,0 +1,6 @@
+s/\([^ ][^ ]*\)/(\1)/g
+2s
+/3/s
+/\(4\)/sr
+/\(.\)/srg
+%s/i/&e/
diff --git a/regress/bin/ed/s10.err b/regress/bin/ed/s10.err
new file mode 100644 (file)
index 0000000..0d8d83d
--- /dev/null
@@ -0,0 +1,4 @@
+a
+hello
+.
+s/[h[.]/x/
diff --git a/regress/bin/ed/s2.d b/regress/bin/ed/s2.d
new file mode 100644 (file)
index 0000000..92f337e
--- /dev/null
@@ -0,0 +1,5 @@
+line 1
+line 2
+line 3
+line 4
+line5
diff --git a/regress/bin/ed/s2.r b/regress/bin/ed/s2.r
new file mode 100644 (file)
index 0000000..ca305c8
--- /dev/null
@@ -0,0 +1,5 @@
+li(n)e 1
+i(n)e 200
+li(n)e 3
+li(n)e 4
+li(n)e500
diff --git a/regress/bin/ed/s2.t b/regress/bin/ed/s2.t
new file mode 100644 (file)
index 0000000..f365849
--- /dev/null
@@ -0,0 +1,4 @@
+,s/./(&)/3
+s/$/00
+2s//%/g
+s/^l
diff --git a/regress/bin/ed/s3.d b/regress/bin/ed/s3.d
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/regress/bin/ed/s3.err b/regress/bin/ed/s3.err
new file mode 100644 (file)
index 0000000..d68c7d0
--- /dev/null
@@ -0,0 +1 @@
+s/[xyx/a/
diff --git a/regress/bin/ed/s3.r b/regress/bin/ed/s3.r
new file mode 100644 (file)
index 0000000..d6cada2
--- /dev/null
@@ -0,0 +1 @@
+hello   world
diff --git a/regress/bin/ed/s3.t b/regress/bin/ed/s3.t
new file mode 100644 (file)
index 0000000..fbf8803
--- /dev/null
@@ -0,0 +1,6 @@
+a
+hello/[]world
+.
+s/[/]/ /
+s/[[:digit:][]/ /
+s/[]]/ /
diff --git a/regress/bin/ed/s4.d b/regress/bin/ed/s4.d
new file mode 100644 (file)
index 0000000..7898192
--- /dev/null
@@ -0,0 +1 @@
+a
diff --git a/regress/bin/ed/s4.err b/regress/bin/ed/s4.err
new file mode 100644 (file)
index 0000000..35b609f
--- /dev/null
@@ -0,0 +1 @@
+s/\a\b\c/xyz/
diff --git a/regress/bin/ed/s4.r b/regress/bin/ed/s4.r
new file mode 100644 (file)
index 0000000..86ae29c
--- /dev/null
@@ -0,0 +1 @@
+ba
diff --git a/regress/bin/ed/s4.t b/regress/bin/ed/s4.t
new file mode 100644 (file)
index 0000000..5e4fe76
--- /dev/null
@@ -0,0 +1 @@
+s/x*/b/g
diff --git a/regress/bin/ed/s5.err b/regress/bin/ed/s5.err
new file mode 100644 (file)
index 0000000..89104c5
--- /dev/null
@@ -0,0 +1 @@
+s//xyz/
diff --git a/regress/bin/ed/s6.err b/regress/bin/ed/s6.err
new file mode 100644 (file)
index 0000000..b478595
--- /dev/null
@@ -0,0 +1 @@
+s
diff --git a/regress/bin/ed/s7.err b/regress/bin/ed/s7.err
new file mode 100644 (file)
index 0000000..30ba4fd
--- /dev/null
@@ -0,0 +1,5 @@
+a
+hello world
+.
+/./
+sr
diff --git a/regress/bin/ed/s8.err b/regress/bin/ed/s8.err
new file mode 100644 (file)
index 0000000..5665767
--- /dev/null
@@ -0,0 +1,4 @@
+a
+hello
+.
+s/[h[=]/x/
diff --git a/regress/bin/ed/s9.err b/regress/bin/ed/s9.err
new file mode 100644 (file)
index 0000000..1ff16dd
--- /dev/null
@@ -0,0 +1,4 @@
+a
+hello
+.
+s/[h[:]/x/
diff --git a/regress/bin/ed/t.d b/regress/bin/ed/t.d
new file mode 100644 (file)
index 0000000..92f337e
--- /dev/null
@@ -0,0 +1,5 @@
+line 1
+line 2
+line 3
+line 4
+line5
diff --git a/regress/bin/ed/t.r b/regress/bin/ed/t.r
new file mode 100644 (file)
index 0000000..2b28547
--- /dev/null
@@ -0,0 +1,16 @@
+line 1
+line 1
+line 1
+line 2
+line 2
+line 3
+line 4
+line5
+line 1
+line 1
+line 1
+line 2
+line 2
+line 3
+line 4
+line5
diff --git a/regress/bin/ed/t.t b/regress/bin/ed/t.t
new file mode 100644 (file)
index 0000000..fcb1368
--- /dev/null
@@ -0,0 +1,3 @@
+1t1
+2,3t2
+,t$
diff --git a/regress/bin/ed/t1.d b/regress/bin/ed/t1.d
new file mode 100644 (file)
index 0000000..92f337e
--- /dev/null
@@ -0,0 +1,5 @@
+line 1
+line 2
+line 3
+line 4
+line5
diff --git a/regress/bin/ed/t1.err b/regress/bin/ed/t1.err
new file mode 100644 (file)
index 0000000..c49c556
--- /dev/null
@@ -0,0 +1 @@
+tt
diff --git a/regress/bin/ed/t1.r b/regress/bin/ed/t1.r
new file mode 100644 (file)
index 0000000..2b28547
--- /dev/null
@@ -0,0 +1,16 @@
+line 1
+line 1
+line 1
+line 2
+line 2
+line 3
+line 4
+line5
+line 1
+line 1
+line 1
+line 2
+line 2
+line 3
+line 4
+line5
diff --git a/regress/bin/ed/t1.t b/regress/bin/ed/t1.t
new file mode 100644 (file)
index 0000000..6b66163
--- /dev/null
@@ -0,0 +1,3 @@
+1t0
+2,3t2
+,t$
diff --git a/regress/bin/ed/t2.d b/regress/bin/ed/t2.d
new file mode 100644 (file)
index 0000000..92f337e
--- /dev/null
@@ -0,0 +1,5 @@
+line 1
+line 2
+line 3
+line 4
+line5
diff --git a/regress/bin/ed/t2.err b/regress/bin/ed/t2.err
new file mode 100644 (file)
index 0000000..c202051
--- /dev/null
@@ -0,0 +1 @@
+t0;-1
diff --git a/regress/bin/ed/t2.r b/regress/bin/ed/t2.r
new file mode 100644 (file)
index 0000000..0c75ff5
--- /dev/null
@@ -0,0 +1,6 @@
+line 1
+line5
+line 2
+line 3
+line 4
+line5
diff --git a/regress/bin/ed/t2.t b/regress/bin/ed/t2.t
new file mode 100644 (file)
index 0000000..5175abd
--- /dev/null
@@ -0,0 +1 @@
+t0;/./
diff --git a/regress/bin/ed/u.d b/regress/bin/ed/u.d
new file mode 100644 (file)
index 0000000..92f337e
--- /dev/null
@@ -0,0 +1,5 @@
+line 1
+line 2
+line 3
+line 4
+line5
diff --git a/regress/bin/ed/u.err b/regress/bin/ed/u.err
new file mode 100644 (file)
index 0000000..caa1ba1
--- /dev/null
@@ -0,0 +1 @@
+.u
diff --git a/regress/bin/ed/u.r b/regress/bin/ed/u.r
new file mode 100644 (file)
index 0000000..ad558d8
--- /dev/null
@@ -0,0 +1,9 @@
+line 1
+hello
+hello world!!
+line 2
+line 3
+line 4
+line5
+hello
+hello world!!
diff --git a/regress/bin/ed/u.t b/regress/bin/ed/u.t
new file mode 100644 (file)
index 0000000..131cb6e
--- /dev/null
@@ -0,0 +1,31 @@
+1;r u.t
+u
+a
+hello
+world
+.
+g/./s//x/\
+a\
+hello\
+world
+u
+u
+u
+a
+hello world!
+.
+u
+1,$d
+u
+2,3d
+u
+c
+hello world!!
+.
+u
+u
+-1;.,+1j
+u
+u
+u
+.,+1t$
diff --git a/regress/bin/ed/v.d b/regress/bin/ed/v.d
new file mode 100644 (file)
index 0000000..92f337e
--- /dev/null
@@ -0,0 +1,5 @@
+line 1
+line 2
+line 3
+line 4
+line5
diff --git a/regress/bin/ed/v.r b/regress/bin/ed/v.r
new file mode 100644 (file)
index 0000000..714db63
--- /dev/null
@@ -0,0 +1,11 @@
+line5
+order
+hello world
+line 1
+order
+line 2
+order
+line 3
+order
+line 4
+order
diff --git a/regress/bin/ed/v.t b/regress/bin/ed/v.t
new file mode 100644 (file)
index 0000000..608a77f
--- /dev/null
@@ -0,0 +1,6 @@
+v/[ ]/m0
+v/[ ]/s/$/\
+hello world
+v/hello /s/lo/p!/\
+a\
+order
diff --git a/regress/bin/ed/w.d b/regress/bin/ed/w.d
new file mode 100644 (file)
index 0000000..92f337e
--- /dev/null
@@ -0,0 +1,5 @@
+line 1
+line 2
+line 3
+line 4
+line5
diff --git a/regress/bin/ed/w.r b/regress/bin/ed/w.r
new file mode 100644 (file)
index 0000000..ac152ba
--- /dev/null
@@ -0,0 +1,10 @@
+line 1
+line 2
+line 3
+line 4
+line5
+line 1
+line 2
+line 3
+line 4
+line5
diff --git a/regress/bin/ed/w.t b/regress/bin/ed/w.t
new file mode 100644 (file)
index 0000000..c2e18bd
--- /dev/null
@@ -0,0 +1,2 @@
+w !cat >\!.z
+r \!.z
diff --git a/regress/bin/ed/w1.err b/regress/bin/ed/w1.err
new file mode 100644 (file)
index 0000000..e2c8a60
--- /dev/null
@@ -0,0 +1 @@
+w /to/some/far-away/place
diff --git a/regress/bin/ed/w2.err b/regress/bin/ed/w2.err
new file mode 100644 (file)
index 0000000..9daf89c
--- /dev/null
@@ -0,0 +1 @@
+ww.o
diff --git a/regress/bin/ed/w3.err b/regress/bin/ed/w3.err
new file mode 100644 (file)
index 0000000..39bbf4c
--- /dev/null
@@ -0,0 +1 @@
+wqp w.o
diff --git a/regress/bin/ed/x.err b/regress/bin/ed/x.err
new file mode 100644 (file)
index 0000000..0953f01
--- /dev/null
@@ -0,0 +1 @@
+.x
diff --git a/regress/bin/ed/z.err b/regress/bin/ed/z.err
new file mode 100644 (file)
index 0000000..6a51a2d
--- /dev/null
@@ -0,0 +1,2 @@
+z
+z