From 8bcf5fe6de83941370260cf8315cd50e5c2e63d7 Mon Sep 17 00:00:00 2001 From: Giacomo Tesio Date: Sat, 26 Nov 2016 04:28:37 +0100 Subject: [PATCH] buildtools.sh: show progress --- buildtools.sh | 26 ++++++++++++++++++++++++-- continuous-build.sh | 3 ++- 2 files changed, 26 insertions(+), 3 deletions(-) diff --git a/buildtools.sh b/buildtools.sh index e4df769..ccd5c83 100755 --- a/buildtools.sh +++ b/buildtools.sh @@ -29,13 +29,24 @@ if [ "$BUILD_GO_TOOLS$BUILD_DRAWTERM" = "truetrue" ]; then git clean -x -d -f $UTILITIES/bin fi if [ "$BUILD_GO_TOOLS" = "true" ]; then - echo -n Building development tools... + echo -n Building development tools. + ( + # Inside parentheses, and therefore a subshell . . . + while [ 1 ] # Endless loop. + do + echo -n "." + sleep 3 + done + ) & + dotter=$! ( GOBIN="$UTILITIES/bin" GOPATH="$UTILITIES/third_party:$UTILITIES" go get -d jehanne/cmd/... && GOBIN="$UTILITIES/bin" GOPATH="$UTILITIES/third_party:$UTILITIES" go install jehanne/cmd/... && GOBIN="$UTILITIES/bin" GOPATH="$UTILITIES/third_party:$UTILITIES" go install github.com/lionkov/ninep/srv/examples/ufs ) STATUS="$?" + kill $dotter + wait $dotter 2>/dev/null if [ ! $STATUS -eq "0" ] then echo "FAIL" @@ -46,7 +57,16 @@ if [ "$BUILD_GO_TOOLS" = "true" ]; then fi if [ "$BUILD_DRAWTERM" = "true" ]; then - echo -n Building drawterm... + echo -n Building drawterm. + ( + # Inside parentheses, and therefore a subshell . . . + while [ 1 ] # Endless loop. + do + echo -n "." + sleep 3 + done + ) & + dotter=$! ( cd $UTILITIES/third_party/src/github.com/0intro/drawterm/ && git clean -xdf > ../drawterm.build.log 2>&1 && @@ -54,6 +74,8 @@ if [ "$BUILD_DRAWTERM" = "true" ]; then mv drawterm $UTILITIES/bin ) STATUS="$?" + kill $dotter + wait $dotter 2>/dev/null if [ $STATUS -eq "0" ] then rm $UTILITIES/third_party/src/github.com/0intro/drawterm.build.log diff --git a/continuous-build.sh b/continuous-build.sh index b3e13dd..7211e8f 100755 --- a/continuous-build.sh +++ b/continuous-build.sh @@ -8,7 +8,8 @@ if [ "${COVERITY_SCAN_BRANCH}" != 1 ]; then export PATH="$JEHANNE/hacking/bin:$PATH" export SH=`which rc` export ARCH=amd64 - git clean -x -d -f + git clean -xdf . + (cd $JEHANNE/hacking; git clean -xdf .) if [ ! -f "$JEHANNE/hacking/bin/ufs" ]; then echo "Cannot find build tools in $JEHANNE/hacking/bin" $JEHANNE/hacking/buildtools.sh