diff --git a/TeamFortressClassic/tfcserver b/TeamFortressClassic/tfcserver index e9790fff0..3d1e72e40 100644 --- a/TeamFortressClassic/tfcserver +++ b/TeamFortressClassic/tfcserver @@ -46,7 +46,7 @@ githubbranch="master" # Steam appid="90" -appidmos="tfc" +appidmod="tfc" # Server Details servicename="tfc-server" diff --git a/lgsm/functions/command_backup.sh b/lgsm/functions/command_backup.sh index d8d52f4bc..68746c1c5 100644 --- a/lgsm/functions/command_backup.sh +++ b/lgsm/functions/command_backup.sh @@ -2,7 +2,7 @@ # LGSM command_backup.sh function # Author: Daniel Gibbs # Website: http://gameservermanagers.com -lgsm_version="271215" +lgsm_version="190316" # Description: Creates a .tar.gz file in the backup directory. @@ -12,11 +12,7 @@ function_selfname="$(basename $(readlink -f "${BASH_SOURCE[0]}"))" check.sh backupname="${servicename}-$(date '+%Y-%m-%d-%H%M%S')" echo "" -echo "${gamename} Backup" -echo "============================" -echo "" -echo "The following backup will be created:" -echo "" +fn_printinfonl "A total of $(du -sh "${rootdir}" --exclude="${backupdir}" | awk '{print $1}') will be compressed into the following backup:" echo "${backupdir}/${backupname}.tar.gz" echo "" while true; do @@ -27,10 +23,11 @@ while true; do * ) echo "Please answer yes or no.";; esac done +echo "" tmuxwc=$(tmux list-sessions 2>&1|awk '{print $1}'|grep -v failed|grep -Ec "^${servicename}:") if [ "${tmuxwc}" -eq 1 ]; then echo "" - fn_print_warning_nl "${servicename} is currently running." + fn_printwarningnl "${servicename} is currently running." sleep 1 while true; do read -p "Stop ${servicename} while running the backup? [y/N]" yn @@ -41,24 +38,14 @@ if [ "${tmuxwc}" -eq 1 ]; then esac done fi -fn_scriptlog "Started" -echo -en "starting backup.\r" -sleep 1 -echo -en "starting backup..\r" -sleep 1 -echo -en "starting backup...\r" -sleep 1 -echo -en "\n" -cd "${rootdir}" +fn_scriptlog "Started backup" +fn_printdots "Backup in progress, please wait..." +sleep 2 if [ ! -d "${backupdir}" ]; then - mkdir -v "${backupdir}" + mkdir "${backupdir}" fi -tar -cvzf "${backupdir}/${backupname}.tar.gz" --exclude "${backupdir}" ./* -echo "" -echo "Backup created: ${backupdir}/${backupname}.tar.gz" -fn_scriptlog "Created: ${backupdir}/${backupname}.tar.gz" +tar -czf "${backupdir}/${backupname}.tar.gz" -C "${rootdir}" --exclude "backups" ./* +fn_printoknl "Backup created: ${backupname}.tar.gz is $(du -sh "${backupdir}/${backupname}.tar.gz" | awk '{print $1}') size" +fn_scriptlog "Complete, Backup created: ${backupdir}/${backupname}.tar.gz is $(du -sh "${backupdir}/${backupname}.tar.gz" | awk '{print $1}') size" sleep 1 -echo "" -fn_print_complete_nl "Complete." -fn_scriptlog "Complete" -echo "" +echo "" \ No newline at end of file diff --git a/lgsm/functions/command_start.sh b/lgsm/functions/command_start.sh index b843a4ae9..ff8bd9648 100644 --- a/lgsm/functions/command_start.sh +++ b/lgsm/functions/command_start.sh @@ -52,7 +52,7 @@ fn_start_teamspeak3(){ date > "${rootdir}/${lockselfname}" cd "${executabledir}" if [ "${ts3serverpass}" == "1" ];then - ./ts3server_startscript.sh start serveradmin_password="${newpassword}" + ./ts3server_startscript.sh start serveradmin_password="${newpassword}" inifile="${servercfgfullpath}" else ./ts3server_startscript.sh start inifile="${servercfgfullpath}" > /dev/null 2>&1 fi diff --git a/lgsm/functions/command_ts3_server_pass.sh b/lgsm/functions/command_ts3_server_pass.sh index eba76523a..a0ca6d66d 100644 --- a/lgsm/functions/command_ts3_server_pass.sh +++ b/lgsm/functions/command_ts3_server_pass.sh @@ -24,7 +24,7 @@ while true; do read -e -i "y" -p "Continue? [y/N]" yn case $yn in [Yy]* ) break;; - [Nn]* ) echo Exiting; return;; + [Nn]* ) echo Exiting; exit;; * ) echo "Please answer yes or no.";; esac done @@ -45,6 +45,7 @@ fn_print_info_nl "Starting server with new password" command_start.sh # Stop server in "new password mode" command_stop.sh +ts3serverpass="0" fn_print_ok_nl "Password applied" fn_scriptlog "New ServerAdmin password applied" sleep 1 diff --git a/lgsm/functions/email.sh b/lgsm/functions/email.sh index 06f9607d3..11ef7820a 100644 --- a/lgsm/functions/email.sh +++ b/lgsm/functions/email.sh @@ -50,9 +50,6 @@ fi echo -e "\e[34mBackups:\t\e[0m${backupdirdu}" fi echo -e "" - echo -e "========================================\nCommand-line Parameters\n========================================" - echo -e "${executable} ${parms}" - echo -e "" echo -e "========================================\nLogs\n========================================" }| sed -r "s/\x1B\[([0-9]{1,2}(;[0-9]{1,2})?)?[m|K]//g"| tee "${scriptlogdir}/${servicename}-email.log" > /dev/null 2>&1 echo -e "\n\n Script log\n===================" >> "${emaillog}" diff --git a/lgsm/functions/install_logs.sh b/lgsm/functions/install_logs.sh index c7ea4b789..65ae75448 100644 --- a/lgsm/functions/install_logs.sh +++ b/lgsm/functions/install_logs.sh @@ -8,7 +8,7 @@ local modulename="Install" if [ "${checklogs}" != "1" ]; then echo "" - echo "Creating log directorys" + echo "Creating log directories" echo "=================================" fi sleep 1 diff --git a/lgsm/functions/install_ut2k4_key.sh b/lgsm/functions/install_ut2k4_key.sh index 53b603de1..9a99c170d 100644 --- a/lgsm/functions/install_ut2k4_key.sh +++ b/lgsm/functions/install_ut2k4_key.sh @@ -12,7 +12,7 @@ echo "=================================" sleep 1 echo "To get your server listed on the Master Server list" echo "you must get a free CD key. Get a key here:" -echo "http://www.unrealtournament.com/ut2004server/cdkey.php" +echo "https://forums.unrealtournament.com/utserver/cdkey.php?2004" echo "" if [ -z "${autoinstall}" ]; then echo "Once you have the key enter it below"