aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMark Linimon <linimon@FreeBSD.org>2010-12-01 02:28:19 +0000
committerMark Linimon <linimon@FreeBSD.org>2010-12-01 02:28:19 +0000
commitd072a14cd72c2e056300fee35f91d5167d4b8fb0 (patch)
treef8428f1d7e7906ab85c01535e6673714f5442789
parent08037129f0ed49372832806f68394387b8cc7fb3 (diff)
downloadports-d072a14cd72c2e056300fee35f91d5167d4b8fb0.tar.gz
ports-d072a14cd72c2e056300fee35f91d5167d4b8fb0.zip
Make an rm command quieter; add some debug comments.
Notes
Notes: svn path=/head/; revision=265486
-rwxr-xr-xTools/portbuild/scripts/dodistfiles4
1 files changed, 3 insertions, 1 deletions
diff --git a/Tools/portbuild/scripts/dodistfiles b/Tools/portbuild/scripts/dodistfiles
index 018ab95917a1..8e5f549044fb 100755
--- a/Tools/portbuild/scripts/dodistfiles
+++ b/Tools/portbuild/scripts/dodistfiles
@@ -39,6 +39,7 @@ cd ${distdir} || exit 1
echo "Removing incomplete downloads"
+# XXX MCL put an existance test here
find ${distdir}/.pbtmp/ -name .done -depth 2 | sed -e 's,/.done$,/,' | sort > .done || exit 1
find -d ${distdir}/.pbtmp/ -type d -mindepth 1 |sed -E -e 's,([^/])$,\1/,' > .alldirs || exit 1
@@ -64,11 +65,12 @@ done
cat .pkgsubdirs | xargs rmdir || exit 1
echo "Moving remaining distfiles"
+# XXX MCL put an existance test here
find ${distdir}/.pbtmp/ -type f -depth 2 \! -name .done | xargs -J % mv % ${distdir}
echo "Cleaning up"
sed -e 's,$,.done,' < .pkgdirs | xargs rm -f || exit 1
cat .pkgdirs | xargs rmdir || exit 1
-rmdir .pbtmp || exit 1
+rmdir -f .pbtmp || exit 1
rm -f .alldirs .done .pkgdirs .pkgsubdirs .subdirs || exit 1