3 # Build a cvs2svn distribution.
6 WC_REV
=`svnversion -n .`
7 DIST_BASE
=cvs2svn-
${VERSION}
8 DIST_FULL
=${DIST_BASE}.
tar.gz
10 if echo ${WC_REV} |
grep -q -e '[^0-9]'; then
11 echo "Packaging requires a single-revision, pristine working copy."
13 echo "Run 'svn update' to get a working copy without mixed revisions,"
14 echo "and make sure there are no local modifications."
18 # Clean up anything that might have been left from a previous run.
19 rm -rf dist MANIFEST cvs2svn-
${VERSION} ${DIST_FULL}
21 # Build the dist, Python's way.
23 mv dist
/${DIST_FULL} .
25 # Unfortunately, building the dist Python's way doesn't seem to give
26 # us an obvious method for including subdirs. So, we rewire it!
29 svn
export -q test-data
${DIST_BASE}/test-data
30 svn
export -q svntest
${DIST_BASE}/svntest
31 svn
export -q www
${DIST_BASE}/www
32 # Oh, and while we're at it, let's fix cvs2svn's version number.
33 sed -e "s/^VERSION = .*/VERSION = '${VERSION}'/" < cvs2svn
> cvs2svn.tmp
34 mv cvs2svn.tmp
${DIST_BASE}/cvs2svn
35 chmod a
+x
${DIST_BASE}/cvs2svn
36 cp cvs2svn
.1 ${DIST_BASE}
37 tar zcf
${DIST_FULL} ${DIST_BASE}
40 # Clean up after this run.