From fda1f76cc50db92d8a9faed1d9ca9a23864beb3c Mon Sep 17 00:00:00 2001 From: Kevin Baensch Date: Wed, 26 Apr 2023 13:30:41 +0200 Subject: [PATCH] Fix missconfigured pipe detection and getopts. --- script/myssh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/script/myssh b/script/myssh index 5c73033..b8c9c41 100755 --- a/script/myssh +++ b/script/myssh @@ -18,7 +18,7 @@ SUBCOMMAND LIST: -c\tRun SQL on CLI instead of GUI" # Detect Pipe -if ! [ -t 1 ] +if ! [ -t 0 ] then USE_CLI=true fi @@ -193,7 +193,7 @@ case "${MAIN_OPTION}" in exit 1 fi - while getopts "u:p:d:c:" o + while getopts "u:p:d:c" o do case "$o" in u) TARGET_HOST_USERNAME="${OPTARG}" ;;