From 2aae74545855e133d6f0e6ce56bbb8995fd1b51e Mon Sep 17 00:00:00 2001 From: Dominik Riebeling Date: Thu, 12 Apr 2012 21:14:11 +0200 Subject: Add new tarball generation script. The old script depended on svn. An earlier version of this script has already been used in the 3.11. branch. Change-Id: Id03abb8f7bd005ede343243194c4453f0b2e8943 --- utils/common/tarball.py | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100755 utils/common/tarball.py (limited to 'utils/common/tarball.py') diff --git a/utils/common/tarball.py b/utils/common/tarball.py new file mode 100755 index 0000000000..57765a55c7 --- /dev/null +++ b/utils/common/tarball.py @@ -0,0 +1,30 @@ +#!/usr/bin/python + +import gitscraper +import os +import sys + +if len(sys.argv) < 2: + print "Usage: %s " % sys.argv[0] + sys.exit() + +repository = os.path.abspath(os.path.dirname(os.path.abspath(__file__)) + "/../..") +if '.' in sys.argv[1]: + version = sys.argv[1] + basename = "rockbox-" + version + ref = "refs/tags/v" + version + "-final" + refs = gitscraper.get_refs(repository) + if ref in refs: + tree = refs[ref] + else: + print "Could not find hash for version!" + sys.exit() +else: + tree = sys.argv[1] + basename = "rockbox-" + tree + +gitscraper.archive_files(repository, tree, [], basename, archive="7z") + +print "done." + + -- cgit v1.2.3