commit:     5830d893c38d77b8d27c132f07a4ce985eb9f994
Author:     Michał Górny <mgorny <AT> gentoo <DOT> org>
AuthorDate: Wed Jul 17 12:57:57 2019 +0000
Commit:     Michał Górny <mgorny <AT> gentoo <DOT> org>
CommitDate: Wed Jul 17 12:57:57 2019 +0000
URL:        https://gitweb.gentoo.org/proj/qa-scripts.git/commit/?id=5830d893

Support quiet/verbose output in pkgcheck2html

Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>

 cgi-bin/get-git-file.sh | 7 ++++++-
 pkgcheck2html           | 2 +-
 2 files changed, 7 insertions(+), 2 deletions(-)

diff --git a/cgi-bin/get-git-file.sh b/cgi-bin/get-git-file.sh
index 5e9fd0d..09f2575 100755
--- a/cgi-bin/get-git-file.sh
+++ b/cgi-bin/get-git-file.sh
@@ -28,7 +28,12 @@ main() {
        fi
 
        # generate HTML from XML
+       local verbose=
        local lfile=${file}
+       if [[ ${file} == *.verbose.html ]]; then
+               file=${file%.verbose.html}.html
+               verbose=--verbose
+       fi
        [[ ${file} == *.html ]] && lfile=${file%.html}.xml
 
        local tree=( $(git ls-tree "${commit}" "${lfile}" 2>/dev/null) )
@@ -58,7 +63,7 @@ main() {
                local ts=$(TZ=UTC git log --format='%cd' --date=iso-local -1 | 
cut -d' ' -f1-2)
 
                git cat-file -p "${tree[2]}" \
-                       | PYTHONIOENCODING=utf8 python 
"${topdir}"/pkgcheck2html/pkgcheck2html.py -t "${ts}" -
+                       | PYTHONIOENCODING=utf8 python 
"${topdir}"/pkgcheck2html/pkgcheck2html.py ${verbose} -t "${ts}" -
        else
                git cat-file -p "${tree[2]}"
        fi

diff --git a/pkgcheck2html b/pkgcheck2html
index 5a94a88..a0d6845 160000
--- a/pkgcheck2html
+++ b/pkgcheck2html
@@ -1 +1 @@
-Subproject commit 5a94a886cda0f466a4dc1130e8ff31069ee13b43
+Subproject commit a0d68457dc19589031f1d57303ad629b3ecb9dc1

Reply via email to