check_logs.sh 562 B

1234567891011121314151617
  1. #!/bin/bash
  2. # LGSM check_logs.sh function
  3. # Author: Daniel Gibbs
  4. # Website: https://gameservermanagers.com
  5. # Description: Checks that log files exist on server start
  6. local commandname="CHECK"
  7. local function_selfname="$(basename $(readlink -f "${BASH_SOURCE[0]}"))"
  8. # Create dir's for the script and console logs
  9. if [ ! -d "${scriptlogdir}" ]||[ ! -d "${consolelogdir}" ]&&[ "${gamename}" != "Teamspeak 3" ]; then
  10. fn_print_dots "Checking for log files"
  11. sleep 0.5
  12. fn_print_info_nl "Checking for log files: Creating log files"
  13. checklogs=1
  14. install_logs.sh
  15. fi