diff options
author | 2009-07-27 23:59:00 +0200 | |
---|---|---|
committer | 2009-07-28 16:01:21 +0200 | |
commit | ddbda8970aa48268505d7cb6bd7104b5a9b8f8cf (patch) | |
tree | 1b7f7307aa862977532c716f22af5a3ab89160e6 /src | |
parent | Added checking for len of dep in create_dep_groups (diff) | |
download | collagen-ddbda8970aa48268505d7cb6bd7104b5a9b8f8cf.tar.gz collagen-ddbda8970aa48268505d7cb6bd7104b5a9b8f8cf.tar.bz2 collagen-ddbda8970aa48268505d7cb6bd7104b5a9b8f8cf.zip |
Added override for package generation
this should simplify further testing
Diffstat (limited to 'src')
-rw-r--r-- | src/matchbox/__init__.py | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/matchbox/__init__.py b/src/matchbox/__init__.py index 5e21e35..de8de41 100644 --- a/src/matchbox/__init__.py +++ b/src/matchbox/__init__.py @@ -84,6 +84,9 @@ class MatchboxServer(object): client_socket.close() def _get_next_package(self): + override = self.__get_override_package() + if override: + return override categories = os.listdir(self.portsettings["PORTDIR"]) cat_ind = random.randint(0,len(categories)-1) selcat = categories[cat_ind] @@ -102,5 +105,16 @@ class MatchboxServer(object): return "%s/%s" % (selcat,selpkg) + def __get_override_package(self): + try: + line = None + fin = open("/tmp/matchbox_override","r") + line = fin.readline() + line = line.strip() + except: + pass + finally: + return line + |