diff options
author | Lucio Andrés Illanes Albornoz (arab, vxp) <lucio@lucioillanes.de> | 2017-11-22 20:01:52 +0000 |
---|---|---|
committer | Lucio Andrés Illanes Albornoz (arab, vxp) <lucio@lucioillanes.de> | 2017-11-22 20:01:52 +0000 |
commit | 648b81db9539b76a52346c1c5be2b54c4a622956 (patch) | |
tree | b25d12c36f15b5ff6479a326d6164c298b55a791 /subr | |
parent | 61ba136088ee6400697c4f6ecb09fe1bbc4076e7 (diff) | |
download | midipix_build-648b81db9539b76a52346c1c5be2b54c4a622956.tar.bz2 midipix_build-648b81db9539b76a52346c1c5be2b54c4a622956.tar.xz |
build.sh, etc/build.usage, subr/ex_setup_args.subr: adds -vvv and -vv.
subr/ex_rtl_log.subr:ex_log_msg(): adds vvvo and vvfo.
Diffstat (limited to 'subr')
-rw-r--r-- | subr/ex_rtl_log.subr | 10 | ||||
-rw-r--r-- | subr/ex_setup_args.subr | 8 |
2 files changed, 17 insertions, 1 deletions
diff --git a/subr/ex_rtl_log.subr b/subr/ex_rtl_log.subr index f4e250a5..31d5cead 100644 --- a/subr/ex_rtl_log.subr +++ b/subr/ex_rtl_log.subr @@ -22,15 +22,23 @@ ex_log_env_vars() { ex_log_msg() { local _lvl="${1}"; shift; - if [ "${_lvl#v}" != "${_lvl}" ]\ + if [ "${_lvl}" = vnfo ]\ && [ ${ARG_VERBOSE:-0} -eq 0 ]; then return; + elif [ "${_lvl}" = vvfo ]\ + && [ ${ARG_VERBOSE1:-0} -eq 0 ]; then + return; + elif [ "${_lvl}" = vvvo ]\ + && [ ${ARG_VERBOSE2:-0} -eq 0 ]; then + return; fi; case "${_lvl}" in failexit) printf "\033[0m\033[${LOG_MSG_FAIL_COLOUR}m"; ;; fail) printf "\033[0m\033[${LOG_MSG_FAIL_COLOUR}m"; ;; info) printf "\033[0m\033[${LOG_MSG_INFO_COLOUR}m"; ;; vnfo) printf "\033[0m\033[${LOG_MSG_INFO_COLOUR}m"; ;; + vvfo) printf "\033[0m\033[${LOG_MSG_INFO_COLOUR}m"; ;; + vvvo) printf "\033[0m\033[${LOG_MSG_INFO_COLOUR}m"; ;; succ) printf "\033[0m\033[${LOG_MSG_SUCC_COLOUR}m"; ;; warn) printf "\033[0m\033[${LOG_MSG_WARN_COLOUR}m"; ;; varn) printf "\033[0m\033[${LOG_MSG_WARN_COLOUR}m"; ;; diff --git a/subr/ex_setup_args.subr b/subr/ex_setup_args.subr index 637a7d38..fed20d69 100644 --- a/subr/ex_setup_args.subr +++ b/subr/ex_setup_args.subr @@ -14,6 +14,8 @@ BUILD_ARGS_SPEC=" ARG_TARBALL:selfarg:-t.gz ARG_TARBALL:selfarg:-t.xz ARG_VERBOSE:-v + ARG_VERBOSE2:-vv + ARG_VERBOSE3:-vvv ARG_XTRACE:-x"; ex_setup_args() { @@ -51,6 +53,12 @@ ex_setup_args() { if [ "${ARG_XTRACE:-0}" -eq 1 ]; then set -o xtrace; fi; + if [ "${ARG_VERBOSE3:-0}" -eq 1 ]; then + ARG_VERBOSE2=1; + fi; + if [ "${ARG_VERBOSE2:-0}" -eq 1 ]; then + ARG_VERBOSE=1; + fi; if [ -n "${ARG_RESTART}" ]; then if [ "${ARG_RESTART%:*}" != "${ARG_RESTART}" ]; then ARG_RESTART_AT="${ARG_RESTART#*:}"; ARG_RESTART="${ARG_RESTART%:*}"; |