From 64b36c0c6716f1c715f569e559d177c8b7fb82c4 Mon Sep 17 00:00:00 2001 From: "Joshua M. Boniface" Date: Sun, 12 Dec 2021 18:49:51 -0500 Subject: [PATCH] Fix missing test command --- templates/install.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/templates/install.sh b/templates/install.sh index 66c1be9..14dfdbd 100755 --- a/templates/install.sh +++ b/templates/install.sh @@ -13,12 +13,12 @@ fi echo active_ttys=( $( w | grep "^root" | awk '{ print $2 }' ) ) echo "Active TTYs: ${active_ttys[@]}" -this_tty=$( tty | sed -e "s/.*tty\(.*\)/\1/" ) +this_tty=$( tty | sed -e "s:/dev/::" ) echo "This TTY: ${this_tty}" echo if [[ ${#active_ttys} -gt 1 ]]; then - if "${active_ttys[@]}" =~ "ttyS" ]]; then + if [[ "${active_ttys[@]}" =~ "ttyS" ]]; then if [[ "${this_tty}" =~ "tty[0-9]+" ]]; then echo "Found more than one TTY and at least one serial TTY!" echo -n "If you wish to run the installer on this graphical TTY instead of the serial TTY, press enter within 15 seconds... "