Add extra warning for user-install

This commit is contained in:
Ben Peddell 2020-03-25 19:54:10 +10:00 committed by GitHub
parent 71b622ab40
commit 1427a7ec35
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -13,6 +13,7 @@ args=()
output=/dev/null
unstable=
userinstall=
userinstall2=
installservice=
for arg in "$@"; do
@ -20,7 +21,8 @@ for arg in "$@"; do
--verbose) output=/dev/fd/1; ;;
--output=*) output="${1#--output=}"; ;;
--unstable) unstable=1; ;;
--perform-user-install) userinstall=yes; ;;
--perform-user-install) userinstall2=yes; ;;
--yes-i-really-want-to-perform-a-user-install) userinstall=yes; ;;
*)
if [ -n "$channel" ]; then
args+="$arg"
@ -35,12 +37,23 @@ if [ -z "$channel" ]; then
channel="master"
fi
if [[ "$steamcmd_user" == "--me" && -z "$userinstall" ]]; then
if [[ "$steamcmd_user" == "--me" && -z "$userinstall2" ]]; then
echo "You have requested a user-install. You probably don't want this."
echo "A user-install will create ~/.config/arkmanager/instances/main.cfg"
echo "This config file will override /etc/arkmanager/instances/main.cfg"
echo "Add --perform-user-install if you really want this."
echo "Add --perform-user-install if you want this."
exit 1
elif [[ "$steamcmd_user" == "--me" && -z "$userinstall" ]]; then
echo "You have requested a user-install. You probably don't want this."
echo "A user-install will create ~/.config/arkmanager/instances/main.cfg"
echo "This config file will override /etc/arkmanager/instances/main.cfg"
echo "Add --yes-i-really-want-to-perform-a-user-install if you really want this."
exit 1
elif [[ "$steamcmd_user" == "--me" ]]; then
echo "You have requested a user-install. You probably don't want this."
echo "A user-install will create ~/.config/arkmanager/instances/main.cfg"
echo "This config file will override /etc/arkmanager/instances/main.cfg"
echo "You have been warned."
fi
function doInstallFromCommit(){