summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBenedikt Boehm <hollow@gentoo.org>2005-12-03 11:26:42 +0000
committerBenedikt Boehm <hollow@gentoo.org>2005-12-03 11:26:42 +0000
commit1a39dbe84177d2b314998eb3bf68f4fc6e6b059f (patch)
tree4008391ab720af4f383dc68cdd5a59be77c802f2
parentsync branch and trunk; fix typos (diff)
downloadbaselayout-vserver-1a39dbe84177d2b314998eb3bf68f4fc6e6b059f.tar.gz
baselayout-vserver-1a39dbe84177d2b314998eb3bf68f4fc6e6b059f.tar.bz2
baselayout-vserver-1a39dbe84177d2b314998eb3bf68f4fc6e6b059f.zip
import tarball.sh script
svn path=/baselayout-vserver/trunk/; revision=148
-rwxr-xr-xmkrelease62
-rwxr-xr-xtarball.sh48
2 files changed, 48 insertions, 62 deletions
diff --git a/mkrelease b/mkrelease
deleted file mode 100755
index 84eec7c..0000000
--- a/mkrelease
+++ /dev/null
@@ -1,62 +0,0 @@
-#!/bin/bash
-
-proj="baselayout-vserver"
-svnroot="http://dev.croup.de/repos/gentoo-vps/${proj}"
-ver=${1:-1.13.0}
-
-usage() {
- echo "Usage: mkrelease"
-}
-
-die() {
- echo $1
- exit ${2:-1}
-}
-
-if [[ $1 != "-f" ]] ; then
- echo "Performing sanity checks (run with -f to skip) ..."
-
- # Check that we're updated
- svnfiles="$( svn status 2>&1 | egrep -v '^(U|P)' )"
- if [[ -n ${svnfiles} ]] ; then
- echo "Refusing to package tarball until svn is in sync:"
- echo "$svnfiles"
- exit 1
- fi
-fi
-
-echo "Creating release tag... "
-
-svn copy ${svnroot}/trunk ${svnroot}/tags/release-${ver} \
- -m "Tagging the ${ver} release of the ${proj} project" &>/dev/null || die "svn copy failed"
-
-
-echo "Make dist tarball..."
-
-dest=dist/${proj}-${ver}
-
-mkdir -p ${dest} &>/dev/null
-
-for x in bin etc init.d sbin src rc-lists man; do
- svn export $x ${dest}/${x}
-done
-
-mkdir -p ${dest}/lib/rcscripts
-svn export --force net-scripts/init.d ${dest}/init.d
-svn export net-scripts/net.modules.d ${dest}/lib/rcscripts/net.modules.d
-svn export --force net-scripts/conf.d ${dest}/etc/conf.d
-
-svn export ChangeLog ${dest}/ChangeLog
-svn export ChangeLog.vserver ${dest}/ChangeLog.vserver
-
-pushd dist/ &>/dev/null || die "pushd failed"
-
-tar cjf ${proj}-${ver}.tar.bz2 ${proj}-${ver} || die "tar failed"
-
-for i in *.tar*; do
- md5sum $i > $i.md5
-done
-
-echo "Tarball ist at `pwd`"
-
-popd &>/dev/null || die "popd failed"
diff --git a/tarball.sh b/tarball.sh
new file mode 100755
index 0000000..ce21999
--- /dev/null
+++ b/tarball.sh
@@ -0,0 +1,48 @@
+#!/bin/bash
+export TMP="${TMP:-/tmp}"
+export V="1.13.0"
+export NAME="baselayout-vserver"
+export DEST="${TMP}/${NAME}-${V}"
+
+if [[ $1 != "-f" ]] ; then
+ echo "Performing sanity checks (run with -f to skip) ..."
+
+ # Check that we're updated
+ svnfiles=$( svn status 2>&1 | egrep -v '^(U|P)' )
+ if [[ -n ${svnfiles} ]] ; then
+ echo "Refusing to package tarball until svn is in sync:"
+ echo "$svnfiles"
+ exit 1
+ fi
+fi
+
+echo "Creating tarball ..."
+rm -rf ${DEST}
+install -d -m0755 ${DEST}
+
+for x in bin etc init.d sbin src rc-lists man ; do
+ cp -ax $x ${DEST}
+done
+
+# do not yet package src/core stuff
+#rm -rf ${DEST}/src/core
+
+# copy net-scripts and remove older stuff
+install -d -m0755 ${DEST}/lib/rcscripts
+cp -ax net-scripts/init.d ${DEST}
+cp -ax net-scripts/net.modules.d ${DEST}/lib/rcscripts
+cp -ax net-scripts/conf.d ${DEST}/etc
+ln -sfn net.lo ${DEST}/init.d/net.eth0
+
+cp ChangeLog ${DEST}
+
+chown -R root:root ${DEST}
+chmod 0755 ${DEST}/sbin/*
+chmod 0755 ${DEST}/init.d/*
+( cd $TMP/${NAME}-${V} ; rm -rf `find -iname .svn` )
+cd $TMP
+tar cjvf ${TMP}/${NAME}-${V}.tar.bz2 ${NAME}-${V}
+rm -rf ${NAME}-${V}
+
+echo
+du -b ${TMP}/${NAME}-${V}.tar.bz2