This commit is contained in:
Heavybullets8 2022-06-13 14:25:37 -06:00
parent e880da61ed
commit 5f2df0a69e

View File

@ -4,7 +4,7 @@
[[ -z "$*" || "-" == "$*" || "--" == "$*" ]] && echo "This script requires an argument, use --help for help" && exit
ARGS="$*"
ARGS="$@"
SCRIPT=$(readlink -f "$0")
SCRIPTPATH=$(dirname "$SCRIPT")
SCRIPTNAME="$0"
@ -21,7 +21,7 @@ git fetch
git checkout $BRANCH
git pull --force
echo "Running the new version..."
bash "$SCRIPTNAME" "${ARGS//\ \-\-self\-update\ }"
exec bash "$SCRIPTNAME" "${ARGS//\ \-\-self\-update\ }"
# Now exit this old instance
exit 1