4
0
Эх сурвалжийг харах

refactor: improve error message in install_config.sh

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.
Daniel Gibbs 2 жил өмнө
parent
commit
81e5fe66ea

+ 1 - 0
lgsm/config-default/config-lgsm/dstserver/_default.cfg

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

+ 1 - 1
lgsm/modules/install_config.sh

@@ -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