From: Mike Frysinger Date: Thu, 15 Dec 2011 15:13:35 +0000 (-0500) Subject: only clean out compiled objects rather than the whole tree (including a lot of source) X-Git-Url: https://git.wh0rd.org/?a=commitdiff_plain;h=0f71e16bfd528d9e48f8ce47ab5f220ca3267723;p=home.git only clean out compiled objects rather than the whole tree (including a lot of source) --- diff --git a/.bin/cros-cbuildbot b/.bin/cros-cbuildbot index 7784d46..3cdacf0 100755 --- a/.bin/cros-cbuildbot +++ b/.bin/cros-cbuildbot @@ -1,5 +1,12 @@ #!/bin/bash +if ! cbuildbot -h >& /dev/null ; then + cd ~/chromiumos || exit 1 +fi + +# cache the sudo timestamp +sudo echo "" >/dev/null + d=/usr/local/google/home/vapier if [[ -d ${d} ]] ; then d+="/trybot" @@ -9,12 +16,24 @@ if [[ -d ${d} ]] ; then fi echo "Cleaning ${d}" - sudo rm -rf ${d} + pushd "${d}" >/dev/null + clean=( + built-sdk.tbz2 + chroot + new-sdk-chroot + #sdks + src/build + test_results.tgz + trybot_archive + ) + sudo rm -rf "${clean[@]}" + popd >/dev/null else exit 1 fi # find all the buildbot branches +echo "Looking up repo branches" repos=$(r b | cut -b4- | awk '$1 == "bb" { # Single repo output: # bb | in src/third_party/portage-stable