From f0ecb578d2cebf1521ccc8f28006a0ae8fdd1359 Mon Sep 17 00:00:00 2001 From: Jan Pokorný Date: Thu, 15 Aug 2013 19:10:27 +0200 Subject: Extended debugging of watch-bz MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Jan Pokorný --- watch-bz | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/watch-bz b/watch-bz index 9a63501..f7190e0 100755 --- a/watch-bz +++ b/watch-bz @@ -87,6 +87,7 @@ while [ $# -ge 1 ]; do CMDLINE_HELP [[ ${CMDLINE_HELP} =~ ^[Yy].*|^$ ]] && less "${BASH_SOURCE}"; exit;; -m|--mine) MINE=1;; + -d|--debug) WATCHBZ_DEBUG=1;; --) shift; break;; -*) CMDLINE_STATUS+=",$(echo "$1" | cut -c2-)";; *) CMDLINE_COMPONENT+=",$1";; @@ -184,6 +185,10 @@ do_watch () { [ "${WATCHBZ_DEBUG}" -ne 0 ] && EXEC="sh -c" TAIL="${HERE}/table-data $SEP | sort | ${PRECOLORIZE} | cut -c-$WIDTH | ${COLORIZE}" [ "${WATCHBZ_DEBUG}" -ne 0 ] && TAIL="cat" + [ "${WATCHBZ_DEBUG}" -ne 0 ] && BUGZILLA+=" --debug" + [ "${WATCHBZ_DEBUG}" -ne 0 ] && echo \ + "${BUGZILLA} --cookiefile=${BUGZILLA_COOKIE} query -c ${COMPONENT} \ + -t \"${STATUS}\" --outputformat ${OUTPUT_FMT} ${QUERY_REST}" ${EXEC} \ "${BUGZILLA} --cookiefile=${BUGZILLA_COOKIE} query -c ${COMPONENT} \ -t \"${STATUS}\" --outputformat ${OUTPUT_FMT} ${QUERY_REST} \ -- cgit