move individual debug checks to mycommands.sh part 2

This commit is contained in:
Kay Marquardt (Gnadelwartz) 2020-07-02 17:24:56 +02:00
parent 28de99eaeb
commit 9b1119d51d
2 changed files with 4 additions and 3 deletions

View File

@ -11,7 +11,7 @@
# This file is public domain in the USA and all free countries. # This file is public domain in the USA and all free countries.
# Elsewhere, consider it to be WTFPLv2. (wtfpl.net/txt/copying) # Elsewhere, consider it to be WTFPLv2. (wtfpl.net/txt/copying)
# #
#### $$VERSION$$ v0.98-0-g5b5447e #### $$VERSION$$ v0.98-3-g28de99e
# #
# Exit Codes: # Exit Codes:
# - 0 success (hopefully) # - 0 success (hopefully)
@ -86,7 +86,8 @@ debug_checks(){
[ -z "${MYTOKEN}" ] && printf "%s: %s\n" "${DATE}" "Bot token is missing! ==========" [ -z "${MYTOKEN}" ] && printf "%s: %s\n" "${DATE}" "Bot token is missing! =========="
check_token "${MYTOKEN}" || printf "%s: %s\n" "${DATE}" "Invalid bot token! ==========" check_token "${MYTOKEN}" || printf "%s: %s\n" "${DATE}" "Invalid bot token! =========="
[ -z "$(getConfigKey "botadmin")" ] && printf "%s: %s\n" "${DATE}" "Bot admin is missing! ==========" [ -z "$(getConfigKey "botadmin")" ] && printf "%s: %s\n" "${DATE}" "Bot admin is missing! =========="
[ -f ".jssh" ] && printf "%s: %s\n" "${DATE}" "Ups, found file \"${PWD:-.}/.jssh\"! ==========" # call user defined debug_checks if exists
_exec_if_function my_debug_checks "${DATE}" "${WHERE}" "$*"
} >>"${DEBUGLOG}" } >>"${DEBUGLOG}"
# get location and name of bashbot.sh # get location and name of bashbot.sh

View File

@ -8,7 +8,7 @@
# #### if you start to develop your own bot, use the clean version of this file: # #### if you start to develop your own bot, use the clean version of this file:
# #### mycommands.clean # #### mycommands.clean
# #
#### $$VERSION$$ v0.98-1-g550387b #### $$VERSION$$ v0.98-2-g2d48670
# #
# uncomment the following lines to overwrite info and help messages # uncomment the following lines to overwrite info and help messages