From 95cc5f51d17066b6abea5dccce9713878efd106d Mon Sep 17 00:00:00 2001 From: Zac Medico Date: Sat, 10 Oct 2009 01:58:52 +0000 Subject: [PATCH] Fix _set module imports for rename, add hardcoded config for system and world, and remove unused sets code. svn path=/main/branches/2.1.7/; revision=14540 --- bin/emaint | 4 +- bin/glsa-check | 317 -------- bin/repoman | 2 +- cnf/sets.conf | 66 -- pym/_emerge/BlockerDB.py | 2 +- pym/_emerge/Scheduler.py | 4 +- pym/_emerge/SetArg.py | 2 +- pym/_emerge/actions.py | 4 +- pym/_emerge/depgraph.py | 4 +- pym/_emerge/main.py | 2 +- pym/_emerge/unmerge.py | 4 +- pym/portage/_sets/__init__.py | 18 +- pym/portage/_sets/dbapi.py | 306 -------- pym/portage/_sets/files.py | 188 +---- pym/portage/_sets/profiles.py | 4 +- pym/portage/_sets/security.py | 87 --- pym/portage/_sets/shell.py | 45 -- pym/portage/glsa.py | 689 ------------------ pym/portage/tests/sets/__init__.py | 0 pym/portage/tests/sets/files/__init__.py | 0 pym/portage/tests/sets/files/__test__ | 0 .../tests/sets/files/testConfigFileSet.py | 33 - .../tests/sets/files/testStaticFileSet.py | 28 - pym/portage/tests/sets/shell/__init__.py | 0 pym/portage/tests/sets/shell/__test__ | 0 pym/portage/tests/sets/shell/testShell.py | 29 - 26 files changed, 34 insertions(+), 1804 deletions(-) delete mode 100755 bin/glsa-check delete mode 100644 cnf/sets.conf delete mode 100644 pym/portage/_sets/dbapi.py delete mode 100644 pym/portage/_sets/security.py delete mode 100644 pym/portage/_sets/shell.py delete mode 100644 pym/portage/glsa.py delete mode 100644 pym/portage/tests/sets/__init__.py delete mode 100644 pym/portage/tests/sets/files/__init__.py delete mode 100644 pym/portage/tests/sets/files/__test__ delete mode 100644 pym/portage/tests/sets/files/testConfigFileSet.py delete mode 100644 pym/portage/tests/sets/files/testStaticFileSet.py delete mode 100644 pym/portage/tests/sets/shell/__init__.py delete mode 100644 pym/portage/tests/sets/shell/__test__ delete mode 100644 pym/portage/tests/sets/shell/testShell.py diff --git a/bin/emaint b/bin/emaint index 2626036e9..e6d75c0a6 100755 --- a/bin/emaint +++ b/bin/emaint @@ -32,7 +32,7 @@ class WorldHandler(object): self.not_installed = [] self.invalid_category = [] self.okay = [] - from portage.sets import load_default_config + from portage._sets import load_default_config setconfig = load_default_config(portage.settings, portage.db[portage.settings["ROOT"]]) self._sets = setconfig.getSets() @@ -44,7 +44,7 @@ class WorldHandler(object): self.found = os.access(self.world_file, os.R_OK) vardb = portage.db[myroot]["vartree"].dbapi - from portage.sets import SETPREFIX + from portage._sets import SETPREFIX sets = self._sets world_atoms = list(sets["world"]) maxval = len(world_atoms) diff --git a/bin/glsa-check b/bin/glsa-check deleted file mode 100755 index 19f451c59..000000000 --- a/bin/glsa-check +++ /dev/null @@ -1,317 +0,0 @@ -#!/usr/bin/python -# Copyright 2008-2009 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Id$ - -from __future__ import print_function - -import sys - -try: - import portage -except ImportError: - from os import path as osp - sys.path.insert(0, osp.join(osp.dirname(osp.dirname(osp.realpath(__file__))), "pym")) - import portage - -from portage import os -from portage.output import * - -from optparse import OptionGroup, OptionParser - -__program__ = "glsa-check" -__author__ = "Marius Mauch " -__version__ = "1.0" - -def cb_version(*args, **kwargs): - """Callback for --version""" - sys.stderr.write("\n"+ __program__ + ", version " + __version__ + "\n") - sys.stderr.write("Author: " + __author__ + "\n") - sys.stderr.write("This program is licensed under the GPL, version 2\n\n") - sys.exit(0) - -# option parsing -parser = OptionParser(usage="%prog