From 760d5a65f1c307ef1a4b5fafe35a2bf3a9b925b6 Mon Sep 17 00:00:00 2001 From: Holger Levsen Date: Wed, 22 Nov 2017 13:57:45 +0000 Subject: reproducible Arch Linux: hide errors from output Signed-off-by: Holger Levsen --- bin/reproducible_html_archlinux.sh | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) (limited to 'bin') diff --git a/bin/reproducible_html_archlinux.sh b/bin/reproducible_html_archlinux.sh index 469c92ef..9068097b 100755 --- a/bin/reproducible_html_archlinux.sh +++ b/bin/reproducible_html_archlinux.sh @@ -58,42 +58,42 @@ for REPOSITORY in $ARCHLINUX_REPOS ; do echo " $PKG" >> $HTML_BUFFER echo " " >> $HTML_BUFFER if [ -z "$(cd $ARCHLINUX_PKG_PATH/ ; ls *.pkg.tar.xz.html 2>/dev/null)" ] ; then - if [ ! -z "$(egrep '^error: failed to prepare transaction \(conflicting dependencies\)' $ARCHLINUX_PKG_PATH/build1.log $ARCHLINUX_PKG_PATH/build2.log)" ] ; then + if [ ! -z "$(egrep '^error: failed to prepare transaction \(conflicting dependencies\)' $ARCHLINUX_PKG_PATH/build1.log $ARCHLINUX_PKG_PATH/build2.log 2>/dev/null)" ] ; then HTML_TARGET=${HTML_DEPWAIT[0]} let NR_DEPWAIT+=1 echo " \"depwait could not resolve dependencies as there are conflicts" >> $HTML_BUFFER - elif [ ! -z "$(egrep '==> ERROR: (Could not resolve all dependencies|.pacman. failed to install missing dependencies)' $ARCHLINUX_PKG_PATH/build1.log $ARCHLINUX_PKG_PATH/build2.log)" ] ; then + elif [ ! -z "$(egrep '==> ERROR: (Could not resolve all dependencies|.pacman. failed to install missing dependencies)' $ARCHLINUX_PKG_PATH/build1.log $ARCHLINUX_PKG_PATH/build2.log 2>/dev/null)" ] ; then HTML_TARGET=${HTML_DEPWAIT[1]} let NR_DEPWAIT+=1 echo " \"depwait could not resolve dependencies" >> $HTML_BUFFER - elif [ ! -z "$(egrep '==> ERROR: (Failure while downloading|One or more PGP signatures could not be verified)' $ARCHLINUX_PKG_PATH/build1.log $ARCHLINUX_PKG_PATH/build2.log)" ] ; then + elif [ ! -z "$(egrep '==> ERROR: (Failure while downloading|One or more PGP signatures could not be verified)' $ARCHLINUX_PKG_PATH/build1.log $ARCHLINUX_PKG_PATH/build2.log 2>/dev/null)" ] ; then HTML_TARGET=${HTML_404[0]} EXTRA_REASON="" let NR_404+=1 - if [ ! -z "$(grep 'FAILED (unknown public key' $ARCHLINUX_PKG_PATH/build1.log $ARCHLINUX_PKG_PATH/build2.log)" ] ; then + if [ ! -z "$(grep 'FAILED (unknown public key' $ARCHLINUX_PKG_PATH/build1.log $ARCHLINUX_PKG_PATH/build2.log 2>/dev/null)" ] ; then HTML_TARGET=${HTML_404[6]} EXTRA_REASON="to verify source with PGP due to unknown public key" - elif [ ! -z "$(grep 'The requested URL returned error: 404' $ARCHLINUX_PKG_PATH/build1.log $ARCHLINUX_PKG_PATH/build2.log)" ] ; then + elif [ ! -z "$(grep 'The requested URL returned error: 404' $ARCHLINUX_PKG_PATH/build1.log $ARCHLINUX_PKG_PATH/build2.log 2>/dev/null)" ] ; then HTML_TARGET=${HTML_404[3]} EXTRA_REASON="with 404 - file not found" - elif [ ! -z "$(grep 'The requested URL returned error: 403' $ARCHLINUX_PKG_PATH/build1.log $ARCHLINUX_PKG_PATH/build2.log)" ] ; then + elif [ ! -z "$(grep 'The requested URL returned error: 403' $ARCHLINUX_PKG_PATH/build1.log $ARCHLINUX_PKG_PATH/build2.log 2>/dev/null)" ] ; then HTML_TARGET=${HTML_404[2]} EXTRA_REASON="with 403 - forbidden" - elif [ ! -z "$(grep 'The requested URL returned error: 500' $ARCHLINUX_PKG_PATH/build1.log $ARCHLINUX_PKG_PATH/build2.log)" ] ; then + elif [ ! -z "$(grep 'The requested URL returned error: 500' $ARCHLINUX_PKG_PATH/build1.log $ARCHLINUX_PKG_PATH/build2.log 2>/dev/null)" ] ; then HTML_TARGET=${HTML_404[4]} EXTRA_REASON="with 500 - internal server error" - elif [ ! -z "$(grep 'The requested URL returned error: 503' $ARCHLINUX_PKG_PATH/build1.log $ARCHLINUX_PKG_PATH/build2.log)" ] ; then + elif [ ! -z "$(grep 'The requested URL returned error: 503' $ARCHLINUX_PKG_PATH/build1.log $ARCHLINUX_PKG_PATH/build2.log 2>/dev/null)" ] ; then HTML_TARGET=${HTML_404[5]} EXTRA_REASON="with 503 - service unavailable" - elif [ ! -z "$(egrep '==> ERROR: One or more PGP signatures could not be verified' $ARCHLINUX_PKG_PATH/build1.log $ARCHLINUX_PKG_PATH/build2.log)" ] ; then + elif [ ! -z "$(egrep '==> ERROR: One or more PGP signatures could not be verified' $ARCHLINUX_PKG_PATH/build1.log $ARCHLINUX_PKG_PATH/build2.log 2>/dev/null)" ] ; then HTML_TARGET=${HTML_404[7]} EXTRA_REASON="to verify source with PGP signatures" - elif [ ! -z "$(grep 'SSL certificate problem: unable to get local issuer certificate' $ARCHLINUX_PKG_PATH/build1.log $ARCHLINUX_PKG_PATH/build2.log)" ] ; then + elif [ ! -z "$(grep 'SSL certificate problem: unable to get local issuer certificate' $ARCHLINUX_PKG_PATH/build1.log $ARCHLINUX_PKG_PATH/build2.log 2>/dev/null)" ] ; then HTML_TARGET=${HTML_404[1]} EXTRA_REASON="with SSL certificate problem" fi echo " \"404 download failed $EXTRA_REASON" >> $HTML_BUFFER - elif [ ! -z "$(egrep '==> ERROR: One or more files did not pass the validity check' $ARCHLINUX_PKG_PATH/build1.log $ARCHLINUX_PKG_PATH/build2.log)" ] ; then + elif [ ! -z "$(egrep '==> ERROR: One or more files did not pass the validity check' $ARCHLINUX_PKG_PATH/build1.log $ARCHLINUX_PKG_PATH/build2.log 2>/dev/null)" ] ; then HTML_TARGET=${HTML_FTBFS[0]} let NR_FTBFS+=1 echo " \"ftbfs failed to verify source" >> $HTML_BUFFER @@ -101,15 +101,15 @@ for REPOSITORY in $ARCHLINUX_REPOS ; do HTML_TARGET=${HTML_FTBFS[1]} let NR_FTBFS+=1 echo " \"ftbfs failed to build, requirements not met" >> $HTML_BUFFER - elif [ ! -z "$(egrep '==> ERROR: A failure occurred in check' $ARCHLINUX_PKG_PATH/build1.log $ARCHLINUX_PKG_PATH/build2.log)" ] ; then + elif [ ! -z "$(egrep '==> ERROR: A failure occurred in check' $ARCHLINUX_PKG_PATH/build1.log $ARCHLINUX_PKG_PATH/build2.log 2>/dev/null)" ] ; then HTML_TARGET=${HTML_FTBFS[2]} let NR_FTBFS+=1 echo " \"ftbfs failed to build while running tests" >> $HTML_BUFFER - elif [ ! -z "$(egrep '==> ERROR: A failure occurred in (build|package)' $ARCHLINUX_PKG_PATH/build1.log $ARCHLINUX_PKG_PATH/build2.log)" ] ; then + elif [ ! -z "$(egrep '==> ERROR: A failure occurred in (build|package)' $ARCHLINUX_PKG_PATH/build1.log $ARCHLINUX_PKG_PATH/build2.log 2>/dev/null)" ] ; then HTML_TARGET=${HTML_FTBFS[3]} let NR_FTBFS+=1 echo " \"ftbfs failed to build" >> $HTML_BUFFER - elif [ ! -z "$(egrep 'makepkg was killed by timeout after' $ARCHLINUX_PKG_PATH/build1.log $ARCHLINUX_PKG_PATH/build2.log)" ] ; then + elif [ ! -z "$(egrep 'makepkg was killed by timeout after' $ARCHLINUX_PKG_PATH/build1.log $ARCHLINUX_PKG_PATH/build2.log 2>/dev/null)" ] ; then HTML_TARGET=${HTML_FTBFS[4]} let NR_FTBFS+=1 echo " \"ftbfs failed to build, killed by timeout" >> $HTML_BUFFER -- cgit v1.2.3-70-g09d2