From 77ebe90ef7340c9e2cb4400858bc0443c72f427f Mon Sep 17 00:00:00 2001 From: Marius Mauch Date: Fri, 26 Oct 2007 01:03:24 +0000 Subject: [PATCH] use SetConfig.getSetAtoms instead of PackageSet.getAtoms for expanding sets to allow recursion, and drop the default 'sets/' prefix for setnames svn path=/main/trunk/; revision=8302 --- pym/_emerge/__init__.py | 5 +++-- pym/portage/sets/__init__.py | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/pym/_emerge/__init__.py b/pym/_emerge/__init__.py index 2aaf5fb33..785e2f746 100644 --- a/pym/_emerge/__init__.py +++ b/pym/_emerge/__init__.py @@ -6503,16 +6503,17 @@ def emerge_main(): else: newargs.append(a) myfiles = newargs + del newargs for s in settings.sets: if SETPREFIX+s in myfiles: # TODO: check if the current setname also resolves to a package name if myaction in ["unmerge", "prune", "clean", "depclean"] and not packagesets[s].supportsOperation("unmerge"): print "emerge: the given set %s does not support unmerge operations" % s return 1 - if not settings.sets[s].getAtoms(): + if not settings.setconfig.getSetAtoms(s): print "emerge: '%s' is an empty set" % s else: - myfiles.extend(settings.sets[s].getAtoms()) + myfiles.extend(settings.setconfig.getSetAtoms(s)) mysets[s] = settings.sets[s] for e in settings.sets[s].errors: print e diff --git a/pym/portage/sets/__init__.py b/pym/portage/sets/__init__.py index 4d5ce25b5..1d39d10ee 100644 --- a/pym/portage/sets/__init__.py +++ b/pym/portage/sets/__init__.py @@ -63,7 +63,7 @@ class SetConfig(SafeConfigParser): try: setname = self.get(sname, "name") except NoOptionError: - setname = "sets/"+sname + setname = sname if hasattr(setclass, "singleBuilder"): try: self.psets[setname] = setclass.singleBuilder(optdict, self.settings, self.trees) -- 2.26.2