Commits

juster  committed d0fd663

Rewrite tclear to be less complicated.

  • Participants
  • Parent commits fdbed56

Comments (0)

Files changed (1)

 #!/bin/sh
 
+PATH="$PATH:."
 IFS='
 '
+./expdate.awk | while read trans
+do
+	IFS=' 	'
+	if echo "$trans" | fgrep -q '*'
+	then
+		echo "$trans"; continue
+	fi
 
-for trans in $(awk '$5 != "*"')
-do
-	echo -n "$trans? " 1>&2
-	read line </dev/tty
-
-	while true
+	while :
 	do
+		echo -n "$trans? " 1>&2
+		IFS='
+'
+		read line </dev/tty
 		case "$line" in
 		[yY]*|'')	echo $trans | awk '{ $5 = "* " $5 } 1'; break ;;
 		[nN]*)	echo $trans; break ;;
 		*)		echo "Enter y (default), n, or q." 1>&2
 		esac
 	done
-done
+done | awk -f pretty.awk