From 66bbe52fef372b4dcbcc96dba598fe7b3310b14e Mon Sep 17 00:00:00 2001 From: Cody Boone Ferguson <53008573+xexyl@users.noreply.github.com> Date: Fri, 2 Feb 2024 08:24:47 -0800 Subject: [PATCH] Add missing try.sh to 2005/giljade/README.md I also slightly improved the script. --- 2005/giljade/README.md | 11 +++-------- 2005/giljade/try.sh | 14 +++++++------- 2 files changed, 10 insertions(+), 15 deletions(-) diff --git a/2005/giljade/README.md b/2005/giljade/README.md index 4c378f30f..37e9fd6ac 100644 --- a/2005/giljade/README.md +++ b/2005/giljade/README.md @@ -29,15 +29,8 @@ For more detailed information see [2005 giljade in bugs.md](/bugs.md#2005-giljad ## Try: ```sh -./giljade > out +./try.sh ``` -Open an xterm with 78 lines. - -```sh -vi out -``` - -Press `^F` (control F) repeatedly. ### Self-test feature to try: @@ -47,6 +40,8 @@ Press `^F` (control F) repeatedly. ./giljade out ``` +NOTE: [try.sh](try.sh) will ask you if you wish to do this. + ## Judges' remarks: diff --git a/2005/giljade/try.sh b/2005/giljade/try.sh index 449747284..7f1b40ec4 100755 --- a/2005/giljade/try.sh +++ b/2005/giljade/try.sh @@ -23,19 +23,19 @@ echo 1>&2 ./giljade > out echo 1>&2 echo "For this next step, make sure to keep pressing space (or hold it down) (q = quit)." 1>&2 -read -r -n 1 -p "Press any key to run: less -rEXF out: " -less -rEXF out - +read -r -n 1 -p "Press any key to continue: " echo 1>&2 +less -rEXFK out +echo 1>&2 + echo "We've left the file 'out' for you in case you wish to open it in vi(m). If" 1>&2 echo "you do we recommend you try holding ctrl-f down in a similar way to how you held" 1>&2 echo "down space above. Of course you can open it in another editor if you wish." 1>&2 echo 1>&2 -read -r -p "Do you wish to run the test suite (y/n) ? " +read -r -p "Do you wish to run the test suite (Y/N)? " if [[ "$REPLY" == "y" || "$REPLY" = "Y" ]]; then - echo "$ make test" 1>&2 + read -r -n 1 -p "Press any key to run: make test: " + echo 1>&2 make test fi - -