log
This commit is contained in:
parent
9b9e503225
commit
a6180ecd65
1 changed files with 6 additions and 6 deletions
12
bash/log.sh
12
bash/log.sh
|
@ -7,14 +7,14 @@ LOG_LEVEL_TRACE=5
|
|||
|
||||
LOG_LEVEL=${LOG_LEVEL_WARN}
|
||||
|
||||
function log_fatal { [ ${LOG_LEVEL} -ge ${LOG_LEVEL_FATAL} ] && echo "${@}" ; }
|
||||
log_fatal() { [ "${LOG_LEVEL}" -ge "${LOG_LEVEL_FATAL}" ] && echo "${@}" ; }
|
||||
|
||||
function log_error { [ ${LOG_LEVEL} -ge ${LOG_LEVEL_ERROR} ] && echo "${@}" ; }
|
||||
log_error() { [ "${LOG_LEVEL}" -ge "${LOG_LEVEL_ERROR}" ] && echo "${@}" ; }
|
||||
|
||||
function log_warn { [ ${LOG_LEVEL} -ge ${LOG_LEVEL_WARN} ] && echo "${@}" ; }
|
||||
log_warn() { [ "${LOG_LEVEL}" -ge "${LOG_LEVEL_WARN}" ] && echo "${@}" ; }
|
||||
|
||||
function log_info { [ ${LOG_LEVEL} -ge ${LOG_LEVEL_INFO} ] && echo "${@}" ; }
|
||||
log_info() { [ "${LOG_LEVEL}" -ge "${LOG_LEVEL_INFO}" ] && echo "${@}" ; }
|
||||
|
||||
function log_debug { [ ${LOG_LEVEL} -ge ${LOG_LEVEL_DEBUG} ] && echo "${@}" ; }
|
||||
log_debug() { [ "${LOG_LEVEL}" -ge "${LOG_LEVEL_DEBUG}" ] && echo "${@}" ; }
|
||||
|
||||
function log_trace { [ ${LOG_LEVEL} -ge ${LOG_LEVEL_TRACE} ] && echo "${@}" ; }
|
||||
log_trace() { [ "${LOG_LEVEL}" -ge "${LOG_LEVEL_TRACE}" ] && echo "${@}" ; }
|
||||
|
|
Loading…
Reference in a new issue