diff --git a/2014/endoh2/Makefile b/2014/endoh2/Makefile index 4befe3606..120097ebf 100644 --- a/2014/endoh2/Makefile +++ b/2014/endoh2/Makefile @@ -201,7 +201,7 @@ clean: fi clobber: clean - ${RM} -f ${TARGET} ${ALT_TARGET} + ${RM} -f ${TARGET} ${ALT_TARGET} ioccc ioccc.c hello hello.c ${RM} -rf *.dSYM @-if [ -e sandwich ]; then \ ${RM} -f sandwich; \ diff --git a/2014/endoh2/try.sh b/2014/endoh2/try.sh index 0fbfd5a61..42a4cdf7f 100755 --- a/2014/endoh2/try.sh +++ b/2014/endoh2/try.sh @@ -15,14 +15,14 @@ make CC="$CC" all >/dev/null || exit 1 # clear screen after compilation so that only the entry is shown clear -read -r -n 1 -p "Press any key to run: echo Hello | ./prog: " +read -r -n 1 -p "Press any key to run: echo Hello | ./prog (space = next page, q = quit): " echo 1>&2 -echo Hello | ./prog +echo Hello | ./prog | less -rEXFK echo 1>&2 -read -r -n 1 -p "Press any key to run: echo IOCCC | ./prog: " +read -r -n 1 -p "Press any key to run: echo IOCCC | ./prog (space = next page, q = quit): " echo 1>&2 -echo IOCCC | ./prog +echo IOCCC | ./prog | less -rEXFK echo 1>&2 read -r -n 1 -p "Press any key to run: echo Hello | ./prog > hello.c: " @@ -30,6 +30,13 @@ echo 1>&2 echo Hello | ./prog > hello.c echo 1>&2 +# we don't use tee(1) above as it makes the message longer and it's not strictly +# necessary +read -r -n 1 -p "Press any key to show hello.c (space = next page, q = quit): " +echo 1>&2 +less -rEXFK hello.c +echo 1>&2 + read -r -n 1 -p "Press any key to compile hello.c: " echo 1>&2 make hello >/dev/null