From: Huaxu Wan Date: Fri, 2 Dec 2011 07:32:04 +0000 (+0800) Subject: dump server log when failed X-Git-Tag: v0.1~33^2~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=5c819318338d2b46a2cb66e019ee18a788b1c353;p=tools%2Fgbs.git dump server log when failed --- diff --git a/data/build.sh b/data/build.sh index 57d1b8f..df2ce5e 100644 --- a/data/build.sh +++ b/data/build.sh @@ -98,8 +98,7 @@ do if [ -n "$status" ]; then break fi - - sleep 1 + if [ -n "$verbose" ]; then length=`curl -s -u$user:$passwd "$HUDSON_SERVER/rest/projects/build/$build_id/console/" | cut -d ',' -f2|cut -d ':' -f2` curl -s -u$user:$passwd "$HUDSON_SERVER/rest/projects/build/$build_id/console/content" -d 'length'=$length -d 'offset'=$offset -G @@ -107,6 +106,7 @@ do else echo -n '.' fi + sleep 1 done echo "" @@ -114,6 +114,7 @@ echo "" result=`echo $result_json|python -mjson.tool |grep result|cut -d '"' -f4` if [ x$result != xSUCCESS ]; then + curl -u$user:$passwd "$HUDSON_SERVER/job/build/$build_id/consoleText" -G die 'Remote Server Exception' else echo "Your local changes has been submitted to build server."