BSD 4_3_Tahoe development
authorCSRG <csrg@ucbvax.Berkeley.EDU>
Sun, 10 Jan 1988 05:42:47 +0000 (21:42 -0800)
committerCSRG <csrg@ucbvax.Berkeley.EDU>
Sun, 10 Jan 1988 05:42:47 +0000 (21:42 -0800)
Work on file usr/src/new/patch/myread

Synthesized-from: CSRG/cd2/4.3tahoe

usr/src/new/patch/myread [new file with mode: 0644]

diff --git a/usr/src/new/patch/myread b/usr/src/new/patch/myread
new file mode 100644 (file)
index 0000000..5c00f7b
--- /dev/null
@@ -0,0 +1,18 @@
+ans='!'
+while expr "X$ans" : "X!" >/dev/null; do
+    read ans
+    case "$ans" in
+    !)
+       sh
+       echo " "
+       echo -n "$rp "
+       ;;
+    !*)
+       set `expr "X$ans" : "X!\(.*\)$"`
+       sh -c "$*"
+       echo " "
+       echo -n "$rp "
+       ;;
+    esac
+done
+rp='Your answer:'