Skip to content

Commit

Permalink
refactor: improve error message in install_config.sh
Browse files Browse the repository at this point in the history
The commit refactors the code in `install_config.sh` to improve the error message when copying a config file. The function `fn_print_failure_eol_nl` is renamed to `fn_print_fail_eol_nl` for clarity and consistency. This change enhances the readability and maintainability of the code.
  • Loading branch information
dgibbs64 committed Sep 30, 2023
1 parent df02b1f commit 81e5fe6
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions lgsm/config-default/config-lgsm/dstserver/_default.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@

## Predefined Parameters | https://docs.linuxgsm.com/configuration/start-parameters
cluster="Cluster_1"
shard="Master"
persistentstorageroot="${HOME}/.klei"
confdir="DoNotStarveTogether"

Expand Down
2 changes: 1 addition & 1 deletion lgsm/modules/install_config.sh
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ fn_default_config_remote() {
changes+=$(cp -nv "${lgsmdir}/config-default/config-game/${config}" "${servercfgdir}/${config}")
fi
if [ "$?" -ne 0 ]; then # shellcheck disable=SC2181
fn_print_failure_eol_nl
fn_print_fail_eol_nl
fn_script_log_fatal "copying config file ${servercfgfullpath}"
elif [ "${changes}" != "" ]; then
fn_print_ok_eol_nl
Expand Down

0 comments on commit 81e5fe6

Please sign in to comment.