summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJesse Plamondon-Willard <Pathoschild@users.noreply.github.com>2022-03-06 18:37:13 -0500
committerGitHub <noreply@github.com>2022-03-06 18:37:13 -0500
commita4bd5cccd559c977649947fc556654bd2b3152fe (patch)
tree9682d08168a380e1b504a05ab105d1820cebeeca /src
parentdebe17724129c947dddf029c725af5224940cd0e (diff)
parentbb31f09977dfd687d0817f7e6bc57ad54a630df8 (diff)
downloadSMAPI-a4bd5cccd559c977649947fc556654bd2b3152fe.tar.gz
SMAPI-a4bd5cccd559c977649947fc556654bd2b3152fe.tar.bz2
SMAPI-a4bd5cccd559c977649947fc556654bd2b3152fe.zip
Merge pull request #832 from Ryhon0/develop
Make SKIP_TERMINAL default to false if not set
Diffstat (limited to 'src')
-rw-r--r--src/SMAPI.Installer/assets/unix-launcher.sh12
1 files changed, 11 insertions, 1 deletions
diff --git a/src/SMAPI.Installer/assets/unix-launcher.sh b/src/SMAPI.Installer/assets/unix-launcher.sh
index 47937f95..6e8d4df3 100644
--- a/src/SMAPI.Installer/assets/unix-launcher.sh
+++ b/src/SMAPI.Installer/assets/unix-launcher.sh
@@ -8,7 +8,17 @@ cd "$(dirname "$0")" || exit $?
# change to true to skip opening a terminal
# This isn't recommended since you won't see errors, warnings, and update alerts.
-SKIP_TERMINAL=false
+OPTS=`getopt -o St --long skip-terminal,terminal -n 'parse-options' -- "$@"`
+while true; do
+ case "$1" in
+ -S | --skip-terminal ) SKIP_TERMINAL=true; shift ;;
+ -t | --terminal ) SKIP_TERMINAL=false; shift ;;
+ -- ) shift; break ;;
+ * ) break ;;
+ esac
+done
+
+${SKIP_TERMINAL:=false}
##########