From b04ec493d6323be5739083152fe02e94904198e2 Mon Sep 17 00:00:00 2001 From: Daniel Gibbs Date: Thu, 28 Sep 2023 22:50:20 +0100 Subject: [PATCH] refactor: improve config location listing - Renamed the function `fn_list_config_locations` to better reflect its purpose. - Updated the output messages to provide clearer information about the config locations. - Added formatting enhancements for better readability. This commit refactors the code related to listing config locations, making it more user-friendly and informative. --- lgsm/modules/install_config.sh | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/lgsm/modules/install_config.sh b/lgsm/modules/install_config.sh index 2ea05debd..f1bd05988 100644 --- a/lgsm/modules/install_config.sh +++ b/lgsm/modules/install_config.sh @@ -161,22 +161,22 @@ fn_set_dst_config_vars() { unset changes } -# Lists local config file locations +# Lists local config locations fn_list_config_locations() { echo -e "" - echo -e "${lightyellow}Config File Locations${default}" - echo -e "=================================" + echo -e "${bold}${lightyellow}Config Locations${default}" + echo -e "${bold}=================================${default}" if [ -n "${servercfgfullpath}" ]; then if [ -f "${servercfgfullpath}" ]; then - echo -e "Game Server Config File: ${servercfgfullpath}" + echo -e "${gamename} config file: ${italic}${servercfgfullpath}${default}" elif [ -d "${servercfgfullpath}" ]; then - echo -e "Game Server Config Dir: ${servercfgfullpath}" + echo -e "${gamename} config directory: ${italic}${servercfgfullpath}" else - echo -e "Config file: ${red}${servercfgfullpath}${default} (${red}FILE MISSING${default})" + echo -e "${gamename} config: ${italic}${red}${servercfgfullpath}${default} (${red}CONFIG IS MISSING${default})" fi fi - echo -e "LinuxGSM Config: ${lgsmdir}/config-lgsm/${gameservername}" - echo -e "Documentation: https://docs.linuxgsm.com/configuration/game-server-config" + echo -e "LinuxGSM config: ${italic}${lgsmdir}/config-lgsm/${gameservername{default}}" + echo -e "Config documentation: ${italic}https://docs.linuxgsm.com/configuration{default}" } if [ "${shortname}" == "sdtd" ]; then