From: thierry Date: Tue, 19 Jan 2010 09:11:57 +0000 (+0000) Subject: oops X-Git-Tag: foo~220 X-Git-Url: http://git.onelab.eu/?a=commitdiff_plain;h=a8c4c361e1b13d1f6cc86c2bc4cecd73c319b934;p=infrastructure.git oops --- diff --git a/scripts/trim-vserver-builds.sh b/scripts/trim-vserver-builds.sh index c612cfc..d539e6f 100755 --- a/scripts/trim-vserver-builds.sh +++ b/scripts/trim-vserver-builds.sh @@ -13,7 +13,7 @@ totrash="BUILD CODEBASES SOURCES tmp" for build in "$@" ; do text_base=$(basename $build .log.txt) - if [ "$text_base" != "$base" ] ; then + if [ "$text_base" != "$build" ] ; then echo "Removing txt link $build" rm "$build" continue @@ -22,9 +22,9 @@ for build in "$@" ; do trashbase=/build/trash/$base [ -d $trashbase ] || mkdir $trashbase for dir in $totrash ; do - if [ -d $build/$dir ] ; then - echo "Trashing $build/$dir" - mv $build/$dir $trashbase/$dir + if [ -d $build/build/$dir ] ; then + echo "Trashing $build/build/$dir" + mv $build/build/$dir $trashbase/$dir fi done done