Author: andar

Revision: 5937

Log:
        Add a basic script to create release tarballs

Diff:
Added: branches/make_release.sh
===================================================================
--- branches/make_release.sh                            (rev 0)
+++ branches/make_release.sh    2009-11-18 18:58:44 UTC (rev 5937)
@@ -0,0 +1,67 @@
+#!/bin/sh
+
+function usage {
+    echo ""
+    echo "Usage: source dest"
+    echo ""
+    echo "source must point to a branch directory to use"
+    echo "dest must be the name of the tarball"
+    echo ""
+    echo "Example: make_release 1.2_RC deluge-1.2.0"
+    echo ""
+}
+
+if [ ! $# == 2 ]; then
+    usage
+    exit
+fi
+
+src="$1"
+dst="$2"
+
+if [ ! -d $src ]; then
+    echo "$src is not a directory!"
+    usage
+    exit
+fi
+
+echo "Attemping svn export of $src to $dst.."
+
+svn export $src $dst
+
+if [ ! $? == 0 ]; then
+    echo "There was an error with the svn export.. Aborting."
+    exit
+fi
+
+REMOVALS=( "$dst/libtorrent" "$dst/win32" "$dst/docs/build" "$dst/docs/source"
+           "$dst/tests" "$dst/deluge/scripts" )
+
+echo "Removing unwanted directories/files.."
+for remove in ${remova...@]}
+do
+    echo "rm -r $remove"
+    rm -r $remove
+done
+
+echo "Creating tarballs.."
+
+tar -czf $dst".tar.gz" $dst
+tar -cjf $dst".tar.bz2" $dst
+tar --lzma -cf $dst".tar.lzma" $dst
+
+echo "Calculating hashes.."
+echo ""
+
+HASHES=( "sha1sum" "md5sum" )
+TARBALLS=( "$dst.tar.gz" "$dst.tar.bz2" "$dst.tar.lzma" )
+
+for h in ${hash...@]}
+do
+    echo "$h:"
+    for tb in ${tarbal...@]}
+    do
+        $h $tb
+    done
+    echo ""
+done


--

You received this message because you are subscribed to the Google Groups 
"deluge-commit" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/deluge-commit?hl=.


Reply via email to