Skip to content

Instantly share code, notes, and snippets.



Last active Dec 15, 2015
What would you like to do?
Debian suite data structure
# -*- encoding: utf-8 -*-
class Suite(object):
def __init__(self, name, maps_to=None): = name
self.maps_to = maps_to
def real_suite(self):
suite = self
while suite.maps_to:
suite = suite.maps_to
return suite
def __unicode__(self):
return u"%s%s" % (, u"" if not self.maps_to else u" (→ %s)" % self.real_suite)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.