diff options
author | Sean Finney <seanius@debian.org> | 2008-09-02 19:30:36 +0200 |
---|---|---|
committer | Sean Finney <seanius@debian.org> | 2008-09-02 19:30:36 +0200 |
commit | e85af5f8a57084d8bc355623f879e13502aa366e (patch) | |
tree | a956135be77effa57cebfc7298e4f3e00a16725e /patchtracker/SourceArchive.py | |
parent | b2dddfefae747818d9442bd4709e4c04de789bec (diff) | |
download | patch-tracker-e85af5f8a57084d8bc355623f879e13502aa366e.tar.gz |
new ReleaseList class to order project releases
Diffstat (limited to 'patchtracker/SourceArchive.py')
-rwxr-xr-x | patchtracker/SourceArchive.py | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/patchtracker/SourceArchive.py b/patchtracker/SourceArchive.py index 832b315..099b506 100755 --- a/patchtracker/SourceArchive.py +++ b/patchtracker/SourceArchive.py @@ -144,6 +144,18 @@ class SourcePackageIndex: def indices(self): return sorted(self.pkgs.iterkeys()) +class ReleaseList: + + def __init__(self, project): + self.project = project + # XXX this is hard coded for now... + self.relorder = {} + self.relorder["debian"] = ["etch", "lenny", "sid", "experimental"] + + def __iter__(self): + for r in self.relorder[self.project]: + yield r + # basic module tests if __name__ == "__main__": import Conf |