[Libreoffice-commits] .: bin/tinbuild

Jan Holesovsky kendy at kemper.freedesktop.org
Tue Oct 12 04:47:00 PDT 2010


 bin/tinbuild |   24 ++++++++++++------------
 1 file changed, 12 insertions(+), 12 deletions(-)

New commits:
commit 6fc7abf6d69c8931af647ee03dafe48ac6ec0370
Author: Jan Holesovsky <kendy at suse.cz>
Date:   Tue Oct 12 13:46:20 2010 +0200

    Improve error reporting if tinbuild.

diff --git a/bin/tinbuild b/bin/tinbuild
index 0c4fa09..d2121d7 100755
--- a/bin/tinbuild
+++ b/bin/tinbuild
@@ -69,12 +69,12 @@ Tinderbox info:
 
 Commits since the last success:
 
-===== build =====
-`git log '--pretty=tformat:%h  %s' --after="$from_date" | sed 's/^/  /'`
+  ===== build =====
+`git log '--pretty=tformat:%h  %s' --after="$last_success" | sed 's/^/  /'`
 
-`bin/g log '--pretty=tformat:%h  %s' --after="$from_date" | sed 's/^/  /'`
+`bin/g log '--pretty=tformat:%h  %s' --after="$last_success" | sed 's/^/  /'`
 
-Log says:
+The error is:
 
 $*
 EOF
@@ -87,7 +87,7 @@ EOF
 	fi
 }
 
-gitHeads()
+gitHeads ()
 {
 	git rev-parse --verify HEAD
 	g rev-parse --verify HEAD
@@ -140,11 +140,11 @@ while true; do
 
 	# try to build
 	if ! err_msg=$(./autogen.sh 2>&1); then
-		reportError committer "autogen.sh / configure failed - error is:" printf '\n' "$err_msg"
+		reportError committer `printf "autogen.sh / configure failed - error is:\n\n$err_msg"`
 	elif ! err_msg=$(./download 2>&1); then
-		reportError committer "download failed - error is:" printf '\n' "$err_msg"
+		reportError committer `printf "download failed - error is:\n\n$err_msg"`
 	elif ! $NICE make dev-install >build.log 2>&1 ; then
-		reportError committer "building failed - error is:" printf '\n' "$(tail -n100 build.log)"
+		reportError committer `printf "building failed - error is:\n\n"` "$(tail -n100 build.log)"
 	else
 		echo build done
 		cp build.log build/
@@ -158,8 +158,8 @@ while true; do
 		mv build "build-$last_success" ||
 		{
 			msg=
-			test -z "$prev_success" || msg=printf '\n' "Leaving 'build-$prev_success' around, exiting now"
-			reportError owner "Cannot move 'build' to 'build-$last_success'" "$msg"
+			test -z "$prev_success" || msg="Leaving 'build-$prev_success' around, exiting now"
+			reportError owner `printf "Cannot move 'build' to 'build-$last_success'\n\n$msg"`
 		}
 
 		if test -n "$prev_success"; then
@@ -176,9 +176,9 @@ while true; do
 		old_head=$(gitHeads) && err_msg=$(git pull -r 2>&1) && err_msg2=$(bin/g pull -r 2>&1) ||
 		{
 			msg=
-			test -z "$prev_success" || msg=printf '\n' "Leaving 'build-$prev_success' around, exiting now"
+			test -z "$prev_success" || msg="Leaving 'build-$prev_success' around, exiting now"
 
-			reportError owner "git repo f*cked up - error is:" printf '\n' $err_msg $err_msg2 "$msg"
+			reportError owner `printf "git repo broken - error is:\n\n$err_msg\n$err_msg2\n$msg"`
 		}
 		new_head=$(gitHeads)
 		


More information about the Libreoffice-commits mailing list