From 77458de033ce302d259e95b9a66c525fcf822dfc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lucio=20Andr=C3=A9s=20Illanes=20Albornoz?= Date: Thu, 26 Aug 2021 15:24:12 +0200 Subject: Log messages at {info,notice,verbose} and {,-v,-vv}. --- subr.rtl/rtl_fileop.subr | 2 +- subr.rtl/rtl_log.subr | 1 + subr.rtl/rtl_platform.subr | 4 ++-- 3 files changed, 4 insertions(+), 3 deletions(-) (limited to 'subr.rtl') diff --git a/subr.rtl/rtl_fileop.subr b/subr.rtl/rtl_fileop.subr index 53666eaf..d69cead7 100644 --- a/subr.rtl/rtl_fileop.subr +++ b/subr.rtl/rtl_fileop.subr @@ -18,7 +18,7 @@ rtlp_fileop_check() { rtlp_fileop_log() { local _msg="${1}"; if [ "${RTLP_FILEOP_LOG:-0}" -eq 1 ]; then - rtl_log_msg debug "${_msg}"; + rtl_log_msg notice "${_msg}"; fi; }; diff --git a/subr.rtl/rtl_log.subr b/subr.rtl/rtl_log.subr index b91d1374..cc692795 100644 --- a/subr.rtl/rtl_log.subr +++ b/subr.rtl/rtl_log.subr @@ -53,6 +53,7 @@ rtl_log_env_vars() { rtl_log_msg() { local _lvl="${1}" _fmt="${2}" _attr=""; shift 2; case "${RTLP_LOG_LVL:-0}" in + -1) rtl_lmatch "info notice verbose debug" "${_lvl}" && return; ;; 0) rtl_lmatch "notice verbose debug" "${_lvl}" && return; ;; 1) rtl_lmatch "verbose debug" "${_lvl}" && return; ;; 2) rtl_lmatch "debug" "${_lvl}" && return; ;; diff --git a/subr.rtl/rtl_platform.subr b/subr.rtl/rtl_platform.subr index ac411c87..d510254a 100644 --- a/subr.rtl/rtl_platform.subr +++ b/subr.rtl/rtl_platform.subr @@ -86,9 +86,9 @@ rtl_rc() { local _nflag="${1}" _cmd="${2}"; shift 2; case "${_nflag}" in 1) if [ "${#}" -gt 0 ]; then - rtl_log_msg notice "Command line: %s %s" "${_cmd}" "${*}"; + rtl_log_msg verbose "Command line: %s %s" "${_cmd}" "${*}"; else - rtl_log_msg notice "Command line: %s" "${_cmd}"; + rtl_log_msg verbose "Command line: %s" "${_cmd}"; fi; ;; *) "${_cmd}" "${@}"; esac; -- cgit v1.2.3