Skip to content

Commit

Permalink
feat: improve error message for unknown game server (#4218)
Browse files Browse the repository at this point in the history
The code changes modify the error message displayed when an unknown game server is entered. The new message now capitalizes the first letter of "unknown" and adds an exit status of 1 to terminate the script.
  • Loading branch information
dgibbs64 authored May 28, 2023
1 parent 29ff74c commit 7ddbbfd
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 5 deletions.
3 changes: 2 additions & 1 deletion linuxgsm.sh
Original file line number Diff line number Diff line change
Expand Up @@ -369,7 +369,8 @@ if [ "${shortname}" == "core" ]; then
if [ "${userinput}" == "${gameservername}" ] || [ "${userinput}" == "${gamename}" ] || [ "${userinput}" == "${shortname}" ]; then
fn_install_file
else
echo -e "[ FAIL ] unknown game server"
echo -e "[ FAIL ] Unknown game server"
exit 1
fi
else
fn_install_getopt
Expand Down
2 changes: 1 addition & 1 deletion tests/tests_fctrserver.sh
Original file line number Diff line number Diff line change
Expand Up @@ -369,7 +369,7 @@ if [ "${shortname}" == "core" ]; then
if [ "${userinput}" == "${gameservername}" ] || [ "${userinput}" == "${gamename}" ] || [ "${userinput}" == "${shortname}" ]; then
fn_install_file
else
echo -e "[ FAIL ] unknown game server"
echo -e "[ FAIL ] Unknown game server"
fi
else
fn_install_getopt
Expand Down
2 changes: 1 addition & 1 deletion tests/tests_jc2server.sh
Original file line number Diff line number Diff line change
Expand Up @@ -370,7 +370,7 @@ if [ "${shortname}" == "core" ]; then
if [ "${userinput}" == "${gameservername}" ] || [ "${userinput}" == "${gamename}" ] || [ "${userinput}" == "${shortname}" ]; then
fn_install_file
else
echo -e "[ FAIL ] unknown game server"
echo -e "[ FAIL ] Unknown game server"
fi
else
fn_install_getopt
Expand Down
2 changes: 1 addition & 1 deletion tests/tests_mcserver.sh
Original file line number Diff line number Diff line change
Expand Up @@ -370,7 +370,7 @@ if [ "${shortname}" == "core" ]; then
if [ "${userinput}" == "${gameservername}" ] || [ "${userinput}" == "${gamename}" ] || [ "${userinput}" == "${shortname}" ]; then
fn_install_file
else
echo -e "[ FAIL ] unknown game server"
echo -e "[ FAIL ] Unknown game server"
fi
else
fn_install_getopt
Expand Down
2 changes: 1 addition & 1 deletion tests/tests_ts3server.sh
Original file line number Diff line number Diff line change
Expand Up @@ -370,7 +370,7 @@ if [ "${shortname}" == "core" ]; then
if [ "${userinput}" == "${gameservername}" ] || [ "${userinput}" == "${gamename}" ] || [ "${userinput}" == "${shortname}" ]; then
fn_install_file
else
echo -e "[ FAIL ] unknown game server"
echo -e "[ FAIL ] Unknown game server"
fi
else
fn_install_getopt
Expand Down

0 comments on commit 7ddbbfd

Please sign in to comment.