summaryrefslogtreecommitdiffstats
path: root/bin
diff options
context:
space:
mode:
authorHolger Levsen <holger@layer-acht.org>2015-10-18 17:58:50 +0200
committerHolger Levsen <holger@layer-acht.org>2015-10-18 17:58:50 +0200
commit9d2bdd78a062c19dfd9072a1aa63f782425fbc92 (patch)
tree6c94e21858b5b24b2f453fef241bc67f6a2644c1 /bin
parent791278a59abc2c5731026785aa69fc43bb84779d (diff)
downloadjenkins.debian.net-9d2bdd78a062c19dfd9072a1aa63f782425fbc92.tar.xz
reproducible arch: cleanup schroot first
Diffstat (limited to 'bin')
-rwxr-xr-xbin/reproducible_build_arch_pkg.sh14
1 files changed, 7 insertions, 7 deletions
diff --git a/bin/reproducible_build_arch_pkg.sh b/bin/reproducible_build_arch_pkg.sh
index bfe37502..ed458801 100755
--- a/bin/reproducible_build_arch_pkg.sh
+++ b/bin/reproducible_build_arch_pkg.sh
@@ -14,18 +14,18 @@ set -e
cleanup_all() {
cd
- # delete main work dir (only on master)
- if [ "$MODE" = "master" ] ; then
- rm $TMPDIR -r
- echo "$(date -u) - $TMPDIR deleted."
+ # delete session if it still exists
+ if [ "$MODE" != "master" ] ; then
+ schroot --end-session -c arch-$SRCPACKAGE-$(basename $TMPDIR) > /dev/null 2>&1 || true
fi
# delete makepkg build dir
if [ ! -z $SRCPACKAGE ] && [ -d /tmp/$SRCPACKAGE-$(basename $TMPDIR) ] ; then
rm -r /tmp/$SRCPACKAGE-$(basename $TMPDIR)
fi
- # delete session if it still exists
- if [ "$MODE" != "master" ] ; then
- schroot --end-session -c arch-$SRCPACKAGE-$(basename $TMPDIR) > /dev/null 2>&1 || true
+ # delete main work dir (only on master)
+ if [ "$MODE" = "master" ] ; then
+ rm $TMPDIR -r
+ echo "$(date -u) - $TMPDIR deleted."
fi
}